tests/restart_syscall: skip if nanosleep looks uninterrupted
* tests/restart_syscall.test: Skip if restart_syscall is not detected and nanosleep syscall looks uninterrupted.
This commit is contained in:
parent
7c2210190a
commit
afa10d877c
@ -7,12 +7,17 @@
|
||||
check_prog sleep
|
||||
check_prog grep
|
||||
run_strace -enanosleep sleep 1
|
||||
grep nanosleep < "$LOG" > /dev/null ||
|
||||
LC_ALL=C grep ^nanosleep < "$LOG" > /dev/null ||
|
||||
framework_skip_ 'sleep does not use nanosleep'
|
||||
|
||||
./set_ptracer_any sleep 2 &
|
||||
sleep 1
|
||||
run_strace -q -erestart_syscall -p $!
|
||||
run_strace -q -erestart_syscall,nanosleep -p $!
|
||||
|
||||
LC_ALL=C grep ^restart_syscall < "$LOG" > /dev/null ||
|
||||
if LC_ALL=C grep -x 'nanosleep({2, 0}, NULL) \+= 0' < "$LOG" > /dev/null; then
|
||||
skip_ 'no restart_syscall, uninterrupted nanosleep'
|
||||
fi
|
||||
|
||||
case "$STRACE_ARCH" in
|
||||
alpha|mips|or1k|s390|s390x)
|
||||
|
Loading…
Reference in New Issue
Block a user