GNOME Bugzilla – Bug 322978
Segfault when closing image while saving it
Last modified: 2008-01-15 13:02:56 UTC
From http://bugs.debian.org/339115 (I personally can't reproduce this, but other people on #gimp like akk have been able to): opening an image (postscript in this case), choosing to save it as a TIFF image, and closing the image I'm saving while the TIFF image options dialog is up (and then clicking save) causes a crash. Here's the backtrace: [moise@mole music/mix/tex]$ LD_LIBRARY_PATH=/usr/lib/debug gdb gimp GNU gdb 6.3.90_20051119-debian Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "i486-linux-gnu"...Using host libthread_db library "/lib/tls/libthread_db.so.1". (gdb) run cd.ps Starting program: /usr/bin/gimp cd.ps [Thread debugging using libthread_db enabled] [New Thread -1217997120 (LWP 23036)] Program received signal SIGSEGV, Segmentation fault.
+ Trace 64380
Thread NaN (LWP 23036)
The problem is that if you close the image while the file save plug-in is running, it causes the dialog to be destroyed, which causes the line gimp_file_dialog_set_sensitive (dialog, TRUE); at the end of the function file_save_dialog_response() to blow up. Fixed by adding a callback g_signal_connect (dialog, "destroy", G_CALLBACK (gtk_widget_destroyed), &dialog); and then checking whether "dialog" is NULL. I will wait for approval before backporting. For HEAD: 2006-05-18 Bill Skaggs <weskaggs@primate.ucdavis.edu> * app/dialogs/file-save-dialog.c: make sure dialog has not been destroyed when setting sensitive; fixes bug #322978.
Now applied to the 2.2 branch as well. Resolving as FIXED.