3 # Check decoding of return values injected into a syscall that "never fails".
5 # Copyright (c) 2018 The strace developers.
8 # SPDX-License-Identifier: GPL-2.0-or-later
10 . "${srcdir=.}/scno_tampering.sh"
12 case "$STRACE_ARCH" in
23 fault_args="-a9 -e trace=${SYSCALL} -e inject=${SYSCALL}:retval="
30 run_strace $fault_args$rval $prog $rval > "$EXP"
31 match_diff "$LOG" "$EXP"
42 case "$SIZEOF_KERNEL_LONG_T" in
49 test_rval 0x7fffffffffffffff
50 test_rval 0x8000000000000000
51 test_rval 0xfffffffffffff000
52 test_rval 0xfffffffffffffffe
53 test_rval 0xffffffffffffffff