From fb1ae073e96d2d468d90d4059b9d41938f2dcf48 Mon Sep 17 00:00:00 2001 From: "Dmitry V. Levin" Date: Wed, 27 Apr 2016 22:36:07 +0000 Subject: [PATCH] Fix decoding of policy argument of get_mempolicy syscall * numa.c (SYS_FUNC(get_mempolicy)): Print policy argument in square brackets to indicate indirect access. --- numa.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/numa.c b/numa.c index 2def40ff..6ea9b5a1 100644 --- a/numa.c +++ b/numa.c @@ -114,8 +114,11 @@ SYS_FUNC(get_mempolicy) { if (exiting(tcp)) { int pol; - if (!umove_or_printaddr(tcp, tcp->u_arg[0], &pol)) + if (!umove_or_printaddr(tcp, tcp->u_arg[0], &pol)) { + tprints("["); printxval(policies, pol, "MPOL_???"); + tprints("]"); + } get_nodes(tcp, tcp->u_arg[1], tcp->u_arg[2], syserror(tcp)); tprints(", "); printaddr(tcp->u_arg[3]); -- 2.40.0