empathy r2016 - trunk/src



Author: xclaesse
Date: Mon Dec 29 09:11:42 2008
New Revision: 2016
URL: http://svn.gnome.org/viewvc/empathy?rev=2016&view=rev

Log:
Don't unref NULL avatar used as chat window icon

This only happens if you set a secret gconf key, I think.

Signed-off-by: Will Thompson <will thompson collabora co uk>

Modified:
   trunk/src/empathy-chat-window.c

Modified: trunk/src/empathy-chat-window.c
==============================================================================
--- trunk/src/empathy-chat-window.c	(original)
+++ trunk/src/empathy-chat-window.c	Mon Dec 29 09:11:42 2008
@@ -325,7 +325,10 @@
 			remote_contact = empathy_chat_get_remote_contact (priv->current_chat);
 			icon = empathy_pixbuf_avatar_from_contact_scaled (remote_contact, 0, 0);
 			gtk_window_set_icon (GTK_WINDOW (priv->dialog), icon);
-			g_object_unref (icon);
+
+			if (icon != NULL) {
+				g_object_unref (icon);
+			}
 		} else {
 			gtk_window_set_icon_name (GTK_WINDOW (priv->dialog), NULL);
 		}



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]