finch/libgnt/gntmenu.c

changeset 19840
cbf074ab46ea
parent 19733
ec657d978c5a
parent 19830
5d2000e59e6f
child 19859
71d37b57eff2
--- a/finch/libgnt/gntmenu.c	Thu Sep 06 06:58:31 2007 +0000
+++ b/finch/libgnt/gntmenu.c	Thu Sep 06 06:59:23 2007 +0000
@@ -221,8 +221,13 @@
 {
 	/* check for a trigger key */
 	GList *iter;
+	GList *find;
 	GList *nth = g_list_find(menu->list, gnt_tree_get_selection_data(GNT_TREE(menu)));
-	GList *find = find_item_with_trigger(nth->next, NULL, trigger);
+
+	if (nth == NULL)
+		return FALSE;
+		
+	find = find_item_with_trigger(nth->next, NULL, trigger);
 	if (!find)
 		find = find_item_with_trigger(menu->list, nth->next, trigger);
 	if (!find)

mercurial