libpurple/protocols/bonjour/mdns_win32.c

branch
release-2.2.3
changeset 20279
77f14669c4dd
parent 20278
9f0a834a6a06
--- a/libpurple/protocols/bonjour/mdns_win32.c	Fri Oct 26 04:57:04 2007 +0000
+++ b/libpurple/protocols/bonjour/mdns_win32.c	Fri Oct 26 05:10:59 2007 +0000
@@ -147,7 +147,11 @@
 	}
 
 	/* free the hosts list*/
-	g_slist_free(hosts);
+	while (hosts != NULL) {
+		hosts = g_slist_remove(hosts, hosts->data);
+		g_free(hosts->data);
+		hosts = g_slist_remove(hosts, hosts->data);
+	}
 
 	/* free the remaining args memory */
 	g_free(args->full_service_name);

mercurial