From 89ca4aa1403daf93284325596e2e4a8fc3bc07ff Mon Sep 17 00:00:00 2001 From: "Dmitry V. Levin" Date: Thu, 12 May 2016 15:03:58 +0000 Subject: [PATCH] ptrace: do not print arguments of PTRACE_TRACEME request As kernel ignores arguments of PTRACE_TRACEME request, we do not print them either. * process.c (SYS_FUNC(ptrace)): If request is PTRACE_TRACEME, return early with RVAL_DECODED. --- process.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/process.c b/process.c index b2dfac19..f53c12e0 100644 --- a/process.c +++ b/process.c @@ -91,6 +91,11 @@ SYS_FUNC(ptrace) /* request */ printxval64(ptrace_cmds, request, "PTRACE_???"); + if (request == PTRACE_TRACEME) { + /* pid, addr, and data are ignored. */ + return RVAL_DECODED; + } + /* pid */ tprintf(", %d, ", pid); -- 2.40.0