[PATCH 08/11] fadvise: Use getarg_ull for obtaining len argument of fadvise64 syscall
Eugene Syromyatnikov
evgsyr at gmail.com
Wed Sep 21 21:21:35 UTC 2016
Since it is size_t, it is 64-bit wide on x32 and special care should be
made in order to obtain it.
* fadvise.c (SYS_FUNC(fadvise64)): Use getarg_ull for obtaining value of
the "len" syscall argument.
---
fadvise.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fadvise.c b/fadvise.c
index 208f533..34933f7 100644
--- a/fadvise.c
+++ b/fadvise.c
@@ -42,7 +42,7 @@ SYS_FUNC(fadvise64)
printfd(tcp, tcp->u_arg[0]);
argn = printllval(tcp, ", %lld", 1);
- tprintf(", %lu, ", tcp->u_arg[argn++]);
+ tprintf(", %llu, ", getarg_ull(tcp, argn++));
printxval(advise, tcp->u_arg[argn], "POSIX_FADV_???");
return RVAL_DECODED;
--
1.7.10.4
More information about the Strace-devel
mailing list