From: Andi Kleen Date: Mon, 13 Jun 2011 21:37:40 +0000 (+0000) Subject: Fix decoding of timer id returned by timer_create X-Git-Tag: v4.7~374 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=732f39656d933c6112a0586bbefcf8288d57bda4;p=strace Fix decoding of timer id returned by timer_create * time.c (sys_timer_create): The kernel returns a integer, not a pointer for the timer id in the memory pointed to by timer_id. --- diff --git a/time.c b/time.c index 6d875518..bd4f11e2 100644 --- a/time.c +++ b/time.c @@ -823,12 +823,12 @@ sys_timer_create(struct tcb *tcp) printsigevent(tcp, tcp->u_arg[1]); tprintf(", "); } else { - void *p; + int timer_id; - if (syserror(tcp) || umove(tcp, tcp->u_arg[2], &p) < 0) + if (syserror(tcp) || umove(tcp, tcp->u_arg[2], &timer_id) < 0) tprintf("%#lx", tcp->u_arg[2]); else - tprintf("{%p}", p); + tprintf("{%d}", timer_id); } return 0; }