# HG changeset patch # User Tim Ringenbach # Date 1087718559 0 # Node ID ef8e4740254d057b0701cf472696306cc10c5a14 # Parent 5ca18080b6bd4174dba849bf7ab5979ae68ad3e0 [gaim-migrate @ 10135] I think this is better. So updating the same GaimBuddyIcon doesn't accidently destroy it. committer: Tailor Script diff -r 5ca18080b6bd -r ef8e4740254d src/buddyicon.c --- a/src/buddyicon.c Sun Jun 20 07:47:20 2004 +0000 +++ b/src/buddyicon.c Sun Jun 20 08:02:39 2004 +0000 @@ -67,11 +67,12 @@ (char *)gaim_buddy_icon_get_username(icon), icon); } + gaim_buddy_icon_ref(icon); gaim_buddy_icon_set_data(icon, icon_data, icon_len); + gaim_buddy_icon_unref(icon); - /* We don't take a reference here. In fact we may want to check if we have - * a reference (gaim_buddy_icon_set_data should have added one or more) - * and destroy ourselves if we don't. + /* We don't take a reference here. gaim_buddy_icon_set_data() makes blist.c or + conversation.c, or both, do that for us. */ return icon; }