From: Bruno Haible Date: Thu, 18 Jul 2024 20:45:41 +0000 (+0200) Subject: abort-debug: Don't assume that signal SIGABRT is unmasked and unhandled. X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=61d3e9ea6445164053f863060906414a86e391ce;p=gnulib.git abort-debug: Don't assume that signal SIGABRT is unmasked and unhandled. * lib/abort-debug.c (rpl_abort): At the end, call the original abort function. --- diff --git a/ChangeLog b/ChangeLog index d1a64b6877..833ecd6d80 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2024-07-18 Bruno Haible + + abort-debug: Don't assume that signal SIGABRT is unmasked and unhandled. + * lib/abort-debug.c (rpl_abort): At the end, call the original abort + function. + 2024-07-18 Bruno Haible abort-debug: Document better. diff --git a/lib/abort-debug.c b/lib/abort-debug.c index 2457ef07c2..cb78c44dc0 100644 --- a/lib/abort-debug.c +++ b/lib/abort-debug.c @@ -26,13 +26,14 @@ /* rpl_abort (); is equivalent to print_stack_trace (); - original abort (); // i.e. raise (SIGABRT); + original abort (); // essentially raise (SIGABRT); */ void rpl_abort (void) +#undef abort { #if HAVE_LIBBACKTRACE || HAVE_LIBASAN || HAVE_EXECINFO_H print_stack_trace_to (stderr); #endif - raise (SIGABRT); + abort (); }