[James LewisMoss <dres dimensional com>] Bug#22030: [libgtk1] shouldn't be catching signals and not coredumping



Here's a bug report from a Debian GTK+ user related to signals, along
with a patch.

-- 
Brought to you by the letters B and O and the number 6.
"Mom! Dad! Don't touch it, it's evil!" *POOF* -- Time Bandits
Ben Gertzfield <http://www.imsa.edu/~wilwonka/> Finger me for my public
PGP key. I'm on FurryMUCK as Che, and EFNet and YiffNet IRC as Che_Fox.
------- Start of forwarded message -------
Subject: Bug#22030: [libgtk1] shouldn't be catching signals and not coredumping
Reply-To: James LewisMoss <dres@dimensional.com>, 22030@bugs.debian.org
Resent-From: James LewisMoss <dres@dimensional.com>
Resent-To: debian-bugs-dist@lists.debian.org
Resent-CC: Ben Gertzfield <che@debian.org>
Resent-Date: Sat, 02 May 1998 18:33:02 GMT
Resent-Message-ID: <handler.22030.B.8941333928416@bugs.debian.org>
Resent-Sender: iwj@debian.org
To: submit@bugs.debian.org
From: James LewisMoss <dres@dimensional.com>
Date: 02 May 1998 12:22:04 -0600
Message-ID: <hhhg388reb.fsf@dres.elam.org>

Package: libgtk1
Version: 1.0.0-1

The gdk lib shouldn't be catching and not core dumping on signals.
IMO it's not the job of the library to do this.  However that is it's
current behavior, so the patch below keeps that behavior unless an
environment var (G_DO_CORE (please change the name if you think of a
better one)) is set.  Then it will call abort like normal. (patch is
from development tree, so it may not apply cleanly)

Dres

----------------------------------------------------------------------
--- gdk.c.old	Sat May  2 12:02:23 1998
+++ gdk.c	Sat May  2 12:04:36 1998
@@ -3184,11 +3184,17 @@
     }
 
   g_print ("\n** ERROR **: %s caught\n", sig);
+
 #ifdef G_ENABLE_DEBUG
-  abort ();
-#else /* !G_ENABLE_DEBUG */
-  gdk_exit (1);
-#endif /* !G_ENABLE_DEBUG */
+#  define G_DO_CORE 1
+#else
+#  define G_DO_CORE 0  
+#endif
+
+  if(G_DO_CORE || getenv("G_DO_CORE"))
+      abort ();
+  else 
+      gdk_exit (1);
 }
 
 static void

------- End of forwarded message -------



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