diff options
author | Eugene Syromiatnikov <esyr@redhat.com> | 2017-12-26 00:15:33 +0100 |
---|---|---|
committer | Dmitry V. Levin <ldv@altlinux.org> | 2019-05-21 23:30:35 +0000 |
commit | 671eaf2f4f12db024eaf52b3d4c07538ffc815d6 (patch) | |
tree | f2207d436b021590fc00b8ce09815f5780ba7c8d | |
parent | ff68f870ae51ff9799727d92d9140e2552580d66 (diff) | |
download | strace-671eaf2f4f12db024eaf52b3d4c07538ffc815d6.tar.gz |
syscall.c: wrap arch_set_scno in TraBAL-specific wrapper
* syscall.c (tamper_with_syscall_entering): Change arch_set_scno call to
set_scno.
(set_scno): New function.
-rw-r--r-- | syscall.c | 10 |
1 files changed, 9 insertions, 1 deletions
@@ -441,6 +441,7 @@ static long get_regs(struct tcb *); static int get_syscall_args(struct tcb *); static int get_syscall_result(struct tcb *); static void get_error(struct tcb *, bool); +int set_scno(struct tcb *, kernel_ulong_t); static void set_error(struct tcb *, unsigned long); static void set_success(struct tcb *, kernel_long_t); static int arch_get_scno(struct tcb *); @@ -496,7 +497,7 @@ tamper_with_syscall_entering(struct tcb *tcp, unsigned int *signo) ? (kernel_long_t) shuffle_scno(opts->data.scno) : -1; - if (!arch_set_scno(tcp, scno)) { + if (!set_scno(tcp, scno)) { tcp->flags |= TCB_TAMPERED; if (scno != -1) tcp->flags |= TCB_TAMPERED_NO_FAIL; @@ -1357,6 +1358,13 @@ get_syscall_args(struct tcb *tcp) return arch_get_syscall_args(tcp); } +int +set_scno(struct tcb *tcp, kernel_ulong_t scno) +{ + return arch_set_scno(tcp, scno); +} + + #ifdef ptrace_getregset_or_getregs # define get_syscall_result_regs get_syscall_regs #else |