changeset 24862:8b55fcc6adde

Fixes from the QuteCom folks for the core being reinitialized. References #7761
author Daniel Atallah <daniel.atallah@gmail.com>
date Thu, 01 Jan 2009 23:07:15 +0000
parents c73a891d26a6
children 0ea515a3f70c fdcb21cd6565
files COPYRIGHT libpurple/prefs.c
diffstat 2 files changed, 10 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/COPYRIGHT	Thu Jan 01 22:43:01 2009 +0000
+++ b/COPYRIGHT	Thu Jan 01 23:07:15 2009 +0000
@@ -63,6 +63,7 @@
 Damien Carbery
 Michael Carlson
 Keegan Carruthers-Smith
+Ludovico Cavedon
 Steve Cavilia
 Julien Cegarra
 Cerulean Studios, LLC
@@ -228,6 +229,7 @@
 Steve Láposi
 Daniel Larsson
 Peter Lawler
+Vadim Lebedev
 Ho-seok Lee
 Jean-Yves Lefort
 Moses Lei
--- a/libpurple/prefs.c	Thu Jan 01 22:43:01 2009 +0000
+++ b/libpurple/prefs.c	Thu Jan 01 23:07:15 2009 +0000
@@ -693,12 +693,15 @@
 	char *name;
 	GSList *l;
 
-	if(!pref || pref == &prefs)
+	if(!pref)
 		return;
 
 	while(pref->first_child)
 		remove_pref(pref->first_child);
 
+	if(pref == &prefs)
+		return;
+
 	if(pref->parent->first_child == pref) {
 		pref->parent->first_child = pref->sibling;
 	} else {
@@ -1452,4 +1455,8 @@
 	}
 
 	purple_prefs_disconnect_by_handle(purple_prefs_get_handle());
+	purple_prefs_destroy();
+	g_hash_table_destroy(prefs_hash);
+	prefs_hash = NULL;
+
 }