strace/tests/sigaltstack.c
Elvira Khabirova 10020ae191 tests: add sigaltstack.test
* tests/sigaltstack.c: New file.
* tests/sigaltstack.expected: Likewise.
* tests/sigaltstack.test: New test.
* tests/Makefile.am (check_PROGRAMS): Add sigaltstack.
(TESTS): Add sigaltstack.test.
(EXTRA_DIST): sigaltstack.expected.
* tests/.gitignore: Add sigaltstack.
2015-07-18 00:01:40 +00:00

13 lines
192 B
C

#include <signal.h>
int
main(void)
{
stack_t ss = {
.ss_sp = (void *) 0xbaadf00d,
.ss_flags = SS_DISABLE,
.ss_size = 0xdeadbeef
};
return sigaltstack(&ss, (stack_t *) 0) ? 77 : 0;
}