diff options
author | Javier Jardón <jjardon@gnome.org> | 2010-07-22 16:43:23 +0200 |
---|---|---|
committer | Javier Jardón <jjardon@gnome.org> | 2010-07-22 17:17:43 +0200 |
commit | c1a2ecc369b8419fdd835bb4d45b48982bfb6dab (patch) | |
tree | 465cfb8e2a289fbdef13a073a1f00bd2c654941e /gtk/gtkplug.c | |
parent | 90db251624eff5e80d8445d159339c72af228be2 (diff) | |
download | gtk+-c1a2ecc369b8419fdd835bb4d45b48982bfb6dab.tar.gz |
Check if childs actually exists before using it
Check seems to have gone lost during GtkBin sealing in commit 4427760b
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=624707
Diffstat (limited to 'gtk/gtkplug.c')
-rw-r--r-- | gtk/gtkplug.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gtk/gtkplug.c b/gtk/gtkplug.c index 5bb003afc0..f1e2a19fe0 100644 --- a/gtk/gtkplug.c +++ b/gtk/gtkplug.c @@ -710,7 +710,8 @@ gtk_plug_map (GtkWidget *widget) gtk_widget_set_mapped (widget, TRUE); child = gtk_bin_get_child (bin); - if (gtk_widget_get_visible (child) && + if (child != NULL && + gtk_widget_get_visible (child) && !gtk_widget_get_mapped (child)) gtk_widget_map (child); @@ -765,7 +766,8 @@ gtk_plug_size_allocate (GtkWidget *widget, allocation->width, allocation->height); child = gtk_bin_get_child (bin); - if (gtk_widget_get_visible (child)) + + if (child != NULL && gtk_widget_get_visible (child)) { GtkAllocation child_allocation; |