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

gEDA-cvs: branch: master updated (1.4.0-20080127-13-g4b53eba)



The branch, master has been updated
       via  4b53eba9204af5eee37c308f23d396df21b2edad (commit)
      from  de64a4f9ff006a80536359d148da9db57594083f (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


=========
 Summary
=========

 gschem/src/x_dialog.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)


=================
 Commit Messages
=================

commit 4b53eba9204af5eee37c308f23d396df21b2edad
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date:   Fri Feb 15 22:24:33 2008 +0000

    Don't change back to a deleted page after the "Save changes?" dialog.
    
    Only switch back to the previous page being edited if that was not
    the one just deleted. Fixes crash or memory corruption after closing
    this dialog.

:100644 100644 0f6caf1... 8c2ba66... M	gschem/src/x_dialog.c

=========
 Changes
=========

commit 4b53eba9204af5eee37c308f23d396df21b2edad
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date:   Fri Feb 15 22:24:33 2008 +0000

    Don't change back to a deleted page after the "Save changes?" dialog.
    
    Only switch back to the previous page being edited if that was not
    the one just deleted. Fixes crash or memory corruption after closing
    this dialog.

diff --git a/gschem/src/x_dialog.c b/gschem/src/x_dialog.c
index 0f6caf1..8c2ba66 100644
--- a/gschem/src/x_dialog.c
+++ b/gschem/src/x_dialog.c
@@ -3967,9 +3967,10 @@ x_dialog_close_changed_page (GSCHEM_TOPLEVEL *w_current, PAGE *page)
   }
   gtk_widget_destroy (dialog);
 
-  /* Switch back to the page we were on */
+  /* Switch back to the page we were on if it wasn't the one being closed */
   g_return_if_fail (keep_page != NULL);
-  s_page_goto (w_current->toplevel, keep_page);
+  if (keep_page != page)
+    s_page_goto (w_current->toplevel, keep_page);
 }
 
 /*! \brief Asks for confirmation before closing a window.




_______________________________________________
geda-cvs mailing list
geda-cvs@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-cvs