Message ID | orsg7ul81x.fsf@lxoliva.fsfla.org |
---|---|
State | New |
Headers | show |
Series | use sigjmp_buf for analyzer sigsetjmp tests | expand |
On Fri, 2020-12-25 at 03:21 -0300, Alexandre Oliva wrote: > 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. > > Regstrapped on x86_64-linux-gnu, also tested on arm-vxworks7r2. > Ok to install? > Sorry about the mistake. The patch looks good to me; I think you can install this under the "obvious" rule. Thanks Dave >
diff --git a/gcc/testsuite/gcc.dg/analyzer/sigsetjmp-5.c b/gcc/testsuite/gcc.dg/analyzer/sigsetjmp-5.c index d6a9910478ce4..494b81352a395 100644 --- a/gcc/testsuite/gcc.dg/analyzer/sigsetjmp-5.c +++ b/gcc/testsuite/gcc.dg/analyzer/sigsetjmp-5.c @@ -4,7 +4,7 @@ #include <stddef.h> #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 f89277efc4847..f5507a3618926 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) {