AUDIT: r15249 - gnucash/trunk/src/gnome-utils - Avoid crash when renaming page in a page-less window by returning if
Andreas Köhler
andi5 at cvs.gnucash.org
Sat Dec 23 01:51:01 EST 2006
Author: andi5
Date: 2006-12-23 01:51:00 -0500 (Sat, 23 Dec 2006)
New Revision: 15249
Trac: http://svn.gnucash.org/trac/changeset/15249
Modified:
gnucash/trunk/src/gnome-utils/gnc-main-window.c
Log:
Avoid crash when renaming page in a page-less window by returning if
there is no current page. Fixes #388841.
BP
Modified: gnucash/trunk/src/gnome-utils/gnc-main-window.c
===================================================================
--- gnucash/trunk/src/gnome-utils/gnc-main-window.c 2006-12-23 06:41:31 UTC (rev 15248)
+++ gnucash/trunk/src/gnome-utils/gnc-main-window.c 2006-12-23 06:51:00 UTC (rev 15249)
@@ -3055,6 +3055,11 @@
ENTER(" ");
priv = GNC_MAIN_WINDOW_GET_PRIVATE(window);
page = priv->current_page;
+ if (!page) {
+ LEAVE("No current page");
+ return;
+ }
+
tab_hbox = gtk_notebook_get_tab_label(GTK_NOTEBOOK(priv->notebook),
page->notebook_page);
children = gtk_container_get_children(GTK_CONTAINER(tab_hbox));
More information about the gnucash-changes
mailing list