menu: Don't leak check menu items

Pointed out in
https://bugzilla.gnome.org/show_bug.cgi?id=774686
This commit is contained in:
Matthias Clasen 2016-11-23 14:48:17 -05:00
parent 1dded6d633
commit 3a947fa318

View File

@ -3056,6 +3056,8 @@ static void gtk_menu_measure (GtkWidget *widget,
max_toggle_size = indicator_width;
gtk_widget_destroy (menu_item);
g_object_ref_sink (menu_item);
g_object_unref (menu_item);
}
min_width += 2 * max_toggle_size + max_accel_width;