From b0a26b94039f2aef74e1ac063d84f7e205375777 Mon Sep 17 00:00:00 2001 From: Eugene Syromyatnikov Date: Wed, 7 Feb 2018 00:58:30 +0100 Subject: [PATCH] syscall.c: print higher bits of syscall return value on x32 personality * syscall.c (syscall_exiting_trace): Check for current_klongsize instead of current_wordsize to determine the size of tcp->u_rval. --- syscall.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/syscall.c b/syscall.c index ce804bf5..1450e3d6 100644 --- a/syscall.c +++ b/syscall.c @@ -916,7 +916,7 @@ syscall_exiting_trace(struct tcb *tcp, struct timeval tv, int res) switch (sys_res & RVAL_MASK) { case RVAL_HEX: #if ANY_WORDSIZE_LESS_THAN_KERNEL_LONG - if (current_wordsize < sizeof(tcp->u_rval)) { + if (current_klongsize < sizeof(tcp->u_rval)) { tprintf("= %#x", (unsigned int) tcp->u_rval); } else @@ -931,7 +931,7 @@ syscall_exiting_trace(struct tcb *tcp, struct timeval tv, int res) break; case RVAL_UDECIMAL: #if ANY_WORDSIZE_LESS_THAN_KERNEL_LONG - if (current_wordsize < sizeof(tcp->u_rval)) { + if (current_klongsize < sizeof(tcp->u_rval)) { tprintf("= %u", (unsigned int) tcp->u_rval); } else -- 2.40.0