strace/tests/prctl-dumpable.test
Eugene Syromyatnikov 73e9623acf tests: check decoding of prctl PR_[GS]ET_DUMPABLE operations
* tests/prctl-dumpable.c: New file.
* tests/prctl-dumpable.test: New test.
* tests/.gitignore: Add prctl-dumpable.
* tests/Makefile.am (check_PROGRAMS): Likewise.
(DECODER_TESTS): Add prctl-dumpable.test.
2016-12-17 12:02:07 +00:00

13 lines
286 B
Bash
Executable File

#!/bin/sh
# Check decoding of prctl PR_GET_DUMPABLE and PR_SET_DUMPABLE operations.
. "${srcdir=.}/init.sh"
check_prog grep
run_prog > /dev/null
run_strace -a23 -eprctl $args > "$EXP"
grep -v '^prctl(PR_[GS]ET_[^D][^U]' < "$LOG" > "$OUT"
match_diff "$OUT" "$EXP"
rm -f "$EXP" "$OUT"