pidgin: de0f6b7b: Fix a crash caused by context menus for ...

sadrul at pidgin.im sadrul at pidgin.im
Thu Apr 22 21:20:45 EDT 2010


-----------------------------------------------------------------
Revision: de0f6b7b9429dd7161de925ce6bdb02fbb7daaec
Ancestor: d72abb9b317d376e2c8c8233e9cb65ea808c8ecc
Author: sadrul at pidgin.im
Date: 2010-04-23T01:24:08
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/de0f6b7b9429dd7161de925ce6bdb02fbb7daaec

Modified files:
        finch/gntblist.c

ChangeLog: 

Fix a crash caused by context menus for sametime buddies.

It looks like prpl/plugins can add a null menu-action for
context-menus. So let's not crash on those. Fixes #11721.

-------------- next part --------------
============================================================
--- finch/gntblist.c	016c02d877d8f782f6ace66343f8e7fb1d77d9e7
+++ finch/gntblist.c	790e940f13586bdac63d428a98e4018abd10f182
@@ -1117,6 +1117,8 @@ append_proto_menu(GntMenu *menu, PurpleC
 			list = g_list_delete_link(list, list))
 	{
 		PurpleMenuAction *act = (PurpleMenuAction *) list->data;
+		if (!act)
+			continue;
 		act->data = node;
 		gnt_append_menu_action(menu, act, NULL);
 		g_signal_connect_swapped(G_OBJECT(menu), "destroy",


More information about the Commits mailing list