From 6ca2610cee82e0bc80331093b7a713f6fc593eec Mon Sep 17 00:00:00 2001 From: "H.J. Lu" Date: Fri, 3 Feb 2012 10:12:10 -0800 Subject: [PATCH] Check HAVE_LONG_LONG_OFF_T when printing offset When HAVE_LONG_LONG_OFF_T is defined, we need to use %llu to print offset. * io.c (sys_sendfile): Check HAVE_LONG_LONG_OFF_T when printing offset. --- io.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/io.c b/io.c index c3075aa8..bc5e110d 100644 --- a/io.c +++ b/io.c @@ -379,7 +379,11 @@ sys_sendfile(struct tcb *tcp) else if (umove(tcp, tcp->u_arg[2], &offset) < 0) tprintf("%#lx", tcp->u_arg[2]); else +#ifdef HAVE_LONG_LONG_OFF_T + tprintf("[%llu]", offset); +#else tprintf("[%lu]", offset); +#endif tprintf(", %lu", tcp->u_arg[3]); } return 0; -- 2.40.0