# HG changeset patch # User Mikael Hallendal # Date 1177436520 -7200 # Node ID b67af7fc111fabf9f003fa3eb6d44df4fbef0985 # Parent 6aefcc6153f4c665a1b6eb02c913fd0aa4414267 Don't free the resolved addresses if they have already been freed. Fixed LM-96 Patch from Senko Rasic diff -r 6aefcc6153f4 -r b67af7fc111f loudmouth/lm-connection.c --- a/loudmouth/lm-connection.c Sun Feb 25 00:13:01 2007 +0100 +++ b/loudmouth/lm-connection.c Tue Apr 24 19:42:00 2007 +0200 @@ -511,9 +511,13 @@ _lm_utils_free_callback (cb); } - freeaddrinfo (connect_data->resolved_addrs); - connection->connect_data = NULL; - g_free (connect_data); + /* If the user callback called connection_close(), this is + * already freed */ + if (connection->connect_data) { + freeaddrinfo (connect_data->resolved_addrs); + connection->connect_data = NULL; + g_free (connect_data); + } } else { /* try to connect to the next host */ connection_do_connect (connect_data);