summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2007-12-10 06:19:53 +0000
committerMatthias Clasen <matthiasc@src.gnome.org>2007-12-10 06:19:53 +0000
commit2a702dcd42be89e44fe85f74cb7727d661438aa7 (patch)
treedf665c28e3e4be20ed2dc2344a31420f1a6f768e
parent494b0e4ca9b3def4ea4392e162dd8ae3b896e7e5 (diff)
downloadgtk+-2a702dcd42be89e44fe85f74cb7727d661438aa7.tar.gz
Another fix to avoid further fallout from the fix for bug 388321.
2007-12-10 Matthias Clasen <mclasen@redhat.com> * gtk/gtknotebook.c (gtk_notebook_real_remove): Another fix to avoid further fallout from the fix for bug 388321. svn path=/trunk/; revision=19139
-rw-r--r--ChangeLog5
-rw-r--r--gtk/gtknotebook.c15
2 files changed, 14 insertions, 6 deletions
diff --git a/ChangeLog b/ChangeLog
index 27ab377642..a2acf30e7b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2007-12-10 Matthias Clasen <mclasen@redhat.com>
+
+ * gtk/gtknotebook.c (gtk_notebook_real_remove): Another fix
+ to avoid further fallout from the fix for bug 388321.
+
2007-12-09 09:56:06 Attilio Fiandrotti <attilio.fiandrotti@gmail.com>
* gdk/directfb/gdkgc-directfb.c:
diff --git a/gtk/gtknotebook.c b/gtk/gtknotebook.c
index 55acbf5b99..80e18fdba5 100644
--- a/gtk/gtknotebook.c
+++ b/gtk/gtknotebook.c
@@ -4349,12 +4349,15 @@ gtk_notebook_real_remove (GtkNotebook *notebook,
gtk_widget_unparent (page->child);
tab_label = page->tab_label;
- g_object_ref (tab_label);
- gtk_notebook_remove_tab_label (notebook, page);
- if (destroying)
- gtk_widget_destroy (tab_label);
- g_object_unref (tab_label);
-
+ if (tab_label)
+ {
+ g_object_ref (tab_label);
+ gtk_notebook_remove_tab_label (notebook, page);
+ if (destroying)
+ gtk_widget_destroy (tab_label);
+ g_object_unref (tab_label);
+ }
+
if (notebook->menu)
{
gtk_container_remove (GTK_CONTAINER (notebook->menu),