diff pidgin/gtkblist.c @ 27556:cbee8aecc90a

Free the buddy list data some more at shutdown and some deprecations. I think these deprecations are reasonable. Basically, purple_blist_init should create a PurpleBuddyList*, so each UI doesn't need to do that. The UI data for the PurpleBuddyList is more tightly coupled with the PurpleBuddyList and purple_blist_destroy is called in purple_blist_uninit (and is fully cleaned up now). As libpurple works currently, I believe it's not really possible to have multiple PurpleBuddyLists around (blist.c relies on a single global variable) and when it was discussed on the mailing list a few months ago, nobody was using it as such. Refs #9253 (going to milestone 3.0.0 it).
author Paul Aurich <paul@darkrain42.org>
date Sun, 12 Jul 2009 02:55:36 +0000
parents b2106bf5a6b4
children 381acdb3cedc
line wrap: on
line diff
--- a/pidgin/gtkblist.c	Sat Jul 11 21:53:52 2009 +0000
+++ b/pidgin/gtkblist.c	Sun Jul 12 02:55:36 2009 +0000
@@ -6714,14 +6714,15 @@
 #endif
 }
 
-
 static void pidgin_blist_destroy(PurpleBuddyList *list)
 {
 	PidginBuddyListPrivate *priv;
 
-	if (!gtkblist)
+	if (!list || !list->ui_data)
 		return;
 
+	g_return_if_fail(list->ui_data != gtkblist);
+
 	purple_signals_disconnect_by_handle(gtkblist);
 
 	if (gtkblist->headline_close)