* m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): In the test program, catch the
SIGABRT signal, so that the program does not dump core.
+2024-02-21 Bruno Haible <bruno@clisp.org>
+
+ *printf-posix: Avoid crash in another configure test.
+ * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): In the test program, catch the
+ SIGABRT signal, so that the program does not dump core.
+
2024-02-20 Bruno Haible <bruno@clisp.org>
unimetadata/u-version: Add tests.
[
AC_RUN_IFELSE(
[AC_LANG_SOURCE([[
+#include <signal.h>
#include <stdio.h>
#include <string.h>
#if HAVE_SNPRINTF
return ret;
}
#endif
+static void
+abort_handler (int sig)
+{
+ (void) sig;
+ _exit (1);
+}
static char fmtstring[10];
static char buf[100];
int main ()
{
int count = -1;
+ signal (SIGABRT, abort_handler);
/* Copy the format string. Some systems (glibc with _FORTIFY_SOURCE=2)
support %n in format strings in read-only memory but not in writable
memory. */