[gtk+/gtk-3-14] GtkMenuSectionBox: Add a clarifying assertion
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/gtk-3-14] GtkMenuSectionBox: Add a clarifying assertion
- Date: Sat, 18 Jul 2015 00:26:11 +0000 (UTC)
commit 9eef97fe1cbee8b469c76ae9fef84751d4b60d19
Author: Matthias Clasen <mclasen redhat com>
Date: Fri Jul 17 20:15:24 2015 -0400
GtkMenuSectionBox: Add a clarifying assertion
This assertion helps coverity see what is clear to us.
gtk/gtkmenusectionbox.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
---
diff --git a/gtk/gtkmenusectionbox.c b/gtk/gtkmenusectionbox.c
index 97eeb5d..957441f 100644
--- a/gtk/gtkmenusectionbox.c
+++ b/gtk/gtkmenusectionbox.c
@@ -262,6 +262,7 @@ open_submenu (GtkWidget *button,
focus = GTK_WIDGET (g_object_get_data (G_OBJECT (button), "focus"));
get_ancestors (focus, GTK_TYPE_STACK, &stack, &child);
+ g_assert (stack != NULL && child != NULL);
gtk_stack_set_visible_child (GTK_STACK (stack), child);
gtk_widget_grab_focus (focus);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]