diff options
author | Marco S Hyman <marc@cvs.openbsd.org> | 2002-10-07 22:17:08 +0000 |
---|---|---|
committer | Marco S Hyman <marc@cvs.openbsd.org> | 2002-10-07 22:17:08 +0000 |
commit | a30a1a4c9478acfbf5b611ad5b4d5cf1d466bb1c (patch) | |
tree | b96c961ed28a268d2f5e9bae67567a35e5b85bf7 /regress/lib/libpthread | |
parent | fe182014368b2a29da019dfd11556ee0a46a9ef2 (diff) |
use/check SA_RESETHAND, too.
Note: until SA_RESETHAND support is fixed the test loops on SIGSEGV
Diffstat (limited to 'regress/lib/libpthread')
-rw-r--r-- | regress/lib/libpthread/siginfo/siginfo.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/regress/lib/libpthread/siginfo/siginfo.c b/regress/lib/libpthread/siginfo/siginfo.c index ab1fb62aac0..605dac9a33e 100644 --- a/regress/lib/libpthread/siginfo/siginfo.c +++ b/regress/lib/libpthread/siginfo/siginfo.c @@ -1,4 +1,4 @@ -/* $OpenBSD: siginfo.c,v 1.1 2002/10/07 21:27:16 marc Exp $ */ +/* $OpenBSD: siginfo.c,v 1.2 2002/10/07 22:17:07 marc Exp $ */ /* PUBLIC DOMAIN Oct 2002 <marc@snafu.org> */ /* test SA_SIGINFO support */ @@ -12,7 +12,8 @@ void act_handler(int signal, siginfo_t *siginfo, void *context) { - ASSERT(siginfo && siginfo->si_addr == (char *) 0x987234 && + ASSERT(siginfo); + ASSERT(siginfo->si_addr == (char *) 0x987234 && siginfo->si_code == 1 && siginfo->si_trapno == 2); } @@ -23,7 +24,7 @@ main(int argc, char **argv) act.sa_sigaction = act_handler; sigemptyset(&act.sa_mask); - act.sa_flags = SA_SIGINFO; + act.sa_flags = SA_SIGINFO | SA_RESETHAND; CHECKe(sigaction(SIGSEGV, &act, NULL)); *(char *) 0x987234 = 1; SUCCEED; |