← Back to team overview

ayatana-commits team mailing list archive

[Merge] lp:~ted/dbusmenu/group-warning-okay into lp:dbusmenu

 

Ted Gould has proposed merging lp:~ted/dbusmenu/group-warning-okay into lp:dbusmenu.

Requested reviews:
  DBus Menu Team (dbusmenu-team)


Scale down the error with no group.
-- 
https://code.launchpad.net/~ted/dbusmenu/group-warning-okay/+merge/29406
Your team ayatana-commits is subscribed to branch lp:dbusmenu.
=== modified file 'libdbusmenu-gtk/menuitem.c'
--- libdbusmenu-gtk/menuitem.c	2010-06-23 19:50:26 +0000
+++ libdbusmenu-gtk/menuitem.c	2010-07-07 17:01:40 +0000
@@ -264,9 +264,10 @@
 
 	GtkAccelGroup * group = gtk_accel_group_from_accel_closure(closure);
 
-	/* Seriously, if this returns NULL something is seriously
-	   wrong in GTK. */
-	g_return_val_if_fail(group != NULL, FALSE);
+	/* Apparently this is more common than I thought. */
+	if (group == NULL) {
+		return FALSE;
+	}
 
 	GtkAccelKey * key = gtk_accel_group_find(group, find_closure, closure);
 	/* Again, not much we can do except complain loudly. */


Follow ups