changeset 32816:071a0e568ac5

merge of '688484ce559f68e7d5e5ac8e67cc667f96c3791a' and '9b2b55b0c80013fc7794f6334575fb6b7e9ed5b7'
author Elliott Sales de Andrade <qulogic@pidgin.im>
date Thu, 31 May 2012 06:20:22 +0000
parents 3d6528f36877 (diff) b31f7945d9b6 (current diff)
children 2c6510167895
files
diffstat 2 files changed, 10 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Thu May 31 06:09:59 2012 +0000
+++ b/ChangeLog	Thu May 31 06:20:22 2012 +0000
@@ -48,7 +48,9 @@
 	  was an offline message. (Flavius Anton) (#2497)
 
 version 2.10.5:
-	No changes
+	Pidgin:
+	* Fix a crash that may occur when trying to ignore a user who is
+	  not in the current chat room. (#15139)
 
 version 2.10.4 (05/06/2012):
 	General:
--- a/pidgin/gtkconv.c	Thu May 31 06:09:59 2012 +0000
+++ b/pidgin/gtkconv.c	Thu May 31 06:20:22 2012 +0000
@@ -6642,10 +6642,13 @@
 
 static gboolean get_iter_from_chatbuddy(PurpleConvChatBuddy *cb, GtkTreeIter *iter)
 {
-	GtkTreeRowReference *ref = purple_conv_chat_cb_get_ui_data(cb);
+	GtkTreeRowReference *ref;
 	GtkTreePath *path;
 	GtkTreeModel *model;
 
+	g_return_val_if_fail(cb != NULL, FALSE);
+
+	ref = purple_conv_chat_cb_get_ui_data(cb);
 	if (!ref)
 		return FALSE;
 
@@ -6825,6 +6828,9 @@
 		return;
 
 	cbuddy = purple_conv_chat_cb_find(chat, user);
+	if (!cbuddy)
+		return;
+
 	if (get_iter_from_chatbuddy(cbuddy, &iter)) {
 		GtkTreeRowReference *ref = purple_conv_chat_cb_get_ui_data(cbuddy);
 		gtk_list_store_remove(GTK_LIST_STORE(model), &iter);