]> granicus.if.org Git - strace/commitdiff
tests/sigaltstack.c: use libtests
authorDmitry V. Levin <ldv@altlinux.org>
Mon, 4 Jan 2016 23:34:00 +0000 (23:34 +0000)
committerDmitry V. Levin <ldv@altlinux.org>
Tue, 5 Jan 2016 23:37:01 +0000 (23:37 +0000)
* tests/sigaltstack.c (main): Use perror_msg_and_skip.

tests/sigaltstack.c

index 10a4b6b02edc99655c4f93781eb01fa3ce386233..884e3c55fadef10b54fcadf610398ccd48f44b86 100644 (file)
@@ -1,3 +1,4 @@
+#include "tests.h"
 #include <signal.h>
 
 int
@@ -8,5 +9,7 @@ main(void)
                .ss_flags = SS_DISABLE,
                .ss_size = 0xdeadbeef
        };
-       return sigaltstack(&ss, (stack_t *) 0) ? 77 : 0;
+       if (sigaltstack(&ss, (stack_t *) 0))
+               perror_msg_and_skip("sigaltstack");
+       return 0;
 }