Silence compiler warnings about implicit cast from pointer to integer

* util.c (do_ptrace): Cast ptrace() 4th arg to long.
(ptrace_restart): Drop void* cast on ptrace() 4th arg.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
This commit is contained in:
Mike Frysinger 2009-10-07 01:13:39 -04:00 committed by Dmitry V. Levin
parent aab05bd713
commit 09a13c2da7

4
util.c
View File

@ -257,7 +257,7 @@ do_ptrace(int request, struct tcb *tcp, void *addr, void *data)
long l;
errno = 0;
l = ptrace(request, tcp->pid, addr, data);
l = ptrace(request, tcp->pid, addr, (long) data);
/* Non-ESRCH errors might be our invalid reg/mem accesses,
* we do not record them. */
if (errno == ESRCH)
@ -279,7 +279,7 @@ ptrace_restart(int op, struct tcb *tcp, int sig)
const char *msg;
errno = 0;
ptrace(op, tcp->pid, (void *) 1, (void *) (long) sig);
ptrace(op, tcp->pid, (void *) 1, (long) sig);
err = errno;
if (!err || err == ESRCH)
return 0;