There's nothing wrong with calling purple_buddy_icons_find() can not receiving an icon in return - it just means that no icon was found. We shouldn't attempt to call purple_buddy_icon_ref() on NULL, which will trigger a failed assertion.

Tue, 08 Jan 2008 02:47:51 +0000

author
Evan Schoenberg <evands@pidgin.im>
date
Tue, 08 Jan 2008 02:47:51 +0000
changeset 22158
270e0052e1b6
parent 22155
7c2034388bdb
child 22159
9539d60302c9
child 22160
eeb909095430

There's nothing wrong with calling purple_buddy_icons_find() can not receiving an icon in return - it just means that no icon was found. We shouldn't attempt to call purple_buddy_icon_ref() on NULL, which will trigger a failed assertion.

libpurple/buddyicon.c file | annotate | diff | comparison | revisions
--- a/libpurple/buddyicon.c	Tue Jan 08 00:22:48 2008 +0000
+++ b/libpurple/buddyicon.c	Tue Jan 08 02:47:51 2008 +0000
@@ -625,7 +625,7 @@
 		purple_buddy_icons_set_caching(caching);
 	}
 
-	return purple_buddy_icon_ref(icon);
+	return (icon ? purple_buddy_icon_ref(icon) : nil);
 }
 
 gboolean

mercurial