From 6541fcadc8622e7b4bf2e90501b51df329e51924 Mon Sep 17 00:00:00 2001 From: Alexandre Oliva Date: Thu, 14 Jan 2021 16:12:20 -0300 Subject: [PATCH] use sigjmp_buf for analyzer sigsetjmp tests The sigsetjmp analyzer tests use jmp_buf in sigsetjmp and siglongjmp calls. Not every system that supports sigsetjmp uses the same data structure for setjmp and sigsetjmp, which results in type mismatches. This patch changes the tests to use sigjmp_buf, that is the POSIX-specific type for use with sigsetjmp and siglongjmp. for gcc/testsuite/ChnageLog * gcc.dg/analyzer/sigsetjmp-5.c: Use sigjmp_buf. * gcc.dg/analyzer/sigsetjmp-6.c: Likewise. --- gcc/testsuite/gcc.dg/analyzer/sigsetjmp-5.c | 2 +- gcc/testsuite/gcc.dg/analyzer/sigsetjmp-6.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/gcc/testsuite/gcc.dg/analyzer/sigsetjmp-5.c b/gcc/testsuite/gcc.dg/analyzer/sigsetjmp-5.c index d6a9910478c..494b81352a3 100644 --- a/gcc/testsuite/gcc.dg/analyzer/sigsetjmp-5.c +++ b/gcc/testsuite/gcc.dg/analyzer/sigsetjmp-5.c @@ -4,7 +4,7 @@ #include #include "analyzer-decls.h" -static jmp_buf env; +static sigjmp_buf env; static void inner (void) { diff --git a/gcc/testsuite/gcc.dg/analyzer/sigsetjmp-6.c b/gcc/testsuite/gcc.dg/analyzer/sigsetjmp-6.c index f89277efc48..f5507a36189 100644 --- a/gcc/testsuite/gcc.dg/analyzer/sigsetjmp-6.c +++ b/gcc/testsuite/gcc.dg/analyzer/sigsetjmp-6.c @@ -6,7 +6,7 @@ extern int foo (int) __attribute__ ((__pure__)); -static jmp_buf env; +static sigjmp_buf env; static void inner (void) { -- 2.30.2