BUG (causing SEGV) in notebook + fix




Hi,

BUG in notebook, causing SEGV - If you don't use tab labels, calling
gtk_notebook_append_page() with NULL as the tab label, a SEGV can occur in
gtk_notebook_button_press().

A patch is included (seems to work OK).

Damon


--- gtknotebook.c~ Mon Mar 16 18:27:13 1998
+++ gtknotebook.c Wed Apr  8 14:13:49 1998
@@ -1543,7 +1543,7 @@
    page = children->data;

    if (GTK_WIDGET_VISIBLE (page->child) &&
-       GTK_WIDGET_MAPPED (page->tab_label) &&
+       page->tab_label && GTK_WIDGET_MAPPED (page->tab_label) &&
        (event->x >= page->allocation.x) &&
        (event->y >= page->allocation.y) &&
        (event->x <= (page->allocation.x + page->allocation.width)) &&







[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]