]> Savannah Git Hosting - gnulib.git/commitdiff
c-stack: port to recent GCC build
authorPaul Eggert <eggert@cs.ucla.edu>
Fri, 23 Mar 2018 18:26:15 +0000 (11:26 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Fri, 23 Mar 2018 18:26:30 +0000 (11:26 -0700)
Problem reported by The Fireplace (Bug#30913).
* lib/c-stack.c (die): Define only if used.

ChangeLog
lib/c-stack.c

index 9b8653f7825bb5b6bfd0991ca73beb937b27c713..9839555c713471ac2994c46cd6b2717e0699e8bf 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2018-03-23  Paul Eggert  <eggert@cs.ucla.edu>
+
+       c-stack: port to recent GCC build
+       Problem reported by The Fireplace (Bug#30913).
+       * lib/c-stack.c (die): Define only if used.
+
 2018-03-20  Bruno Haible  <bruno@clisp.org>
 
        euidaccess: Port to native Windows.
index ddb3c939cb9c54646250c35a916775a992fb3e0f..c309666fee713315a94a61d82ca4b826a9b23c57 100644 (file)
@@ -99,6 +99,10 @@ static void (* volatile segv_action) (int);
 static char const * volatile program_error_message;
 static char const * volatile stack_overflow_message;
 
+#if ((HAVE_LIBSIGSEGV && ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC) \
+     || (HAVE_SIGALTSTACK && HAVE_DECL_SIGALTSTACK            \
+         && HAVE_STACK_OVERFLOW_HANDLING && SIGINFO_WORKS))
+
 /* Output an error message, then exit with status EXIT_FAILURE if it
    appears to have been a stack overflow, or with a core dump
    otherwise.  This function is async-signal-safe.  */
@@ -124,6 +128,7 @@ die (int signo)
   raise (signo);
   abort ();
 }
+#endif
 
 #if (HAVE_SIGALTSTACK && HAVE_DECL_SIGALTSTACK \
      && HAVE_STACK_OVERFLOW_HANDLING) || HAVE_LIBSIGSEGV