libgimp: properly catch SIGABRT signal.

SIGABRT was in the switch list in gimp_plugin_sigfatal_handler(), but it
had not been properly handled with gimp_signal_private(), making this
switch case useless. Fix this oversight, and while doing so, move it in
the "fatal error" list for which we may generate stack traces, similarly
to core signal handling. Indeed this signal can definitely happen during
various kinds of common bugs and needs to be debugged.
This commit is contained in:
Jehan 2018-04-04 04:03:42 +02:00
parent 6936a655bd
commit c46211190f

View file

@ -486,9 +486,11 @@ gimp_main (const GimpPlugInInfo *info,
gimp_signal_private (SIGHUP, gimp_plugin_sigfatal_handler, 0);
gimp_signal_private (SIGINT, gimp_plugin_sigfatal_handler, 0);
gimp_signal_private (SIGQUIT, gimp_plugin_sigfatal_handler, 0);
gimp_signal_private (SIGTERM, gimp_plugin_sigfatal_handler, 0);
gimp_signal_private (SIGABRT, gimp_plugin_sigfatal_handler, 0);
gimp_signal_private (SIGBUS, gimp_plugin_sigfatal_handler, 0);
gimp_signal_private (SIGSEGV, gimp_plugin_sigfatal_handler, 0);
gimp_signal_private (SIGTERM, gimp_plugin_sigfatal_handler, 0);
gimp_signal_private (SIGFPE, gimp_plugin_sigfatal_handler, 0);
/* Ignore SIGPIPE from crashing Gimp */
@ -1907,11 +1909,11 @@ gimp_plugin_sigfatal_handler (gint sig_num)
case SIGHUP:
case SIGINT:
case SIGQUIT:
case SIGABRT:
case SIGTERM:
g_printerr ("%s terminated: %s\n", progname, g_strsignal (sig_num));
break;
case SIGABRT:
case SIGBUS:
case SIGSEGV:
case SIGFPE: