* [RFC,PATCH 10/14] ptrace_signal: check PT_PTRACED before reporting a signal
@ 2009-11-24 20:02 Oleg Nesterov
0 siblings, 0 replies; only message in thread
From: Oleg Nesterov @ 2009-11-24 20:02 UTC (permalink / raw)
To: Alexey Dobriyan, Ananth Mavinakayanahalli, Christoph Hellwig,
Frank Ch. Eigler, Ingo Molnar, Peter Zijlstra, Roland McGrath
Cc: linux-kernel, utrace-devel
No functional changes, preparation for utrace-ptrace.
Change ptrace_signal() to check PT_PTRACED instead of task_ptrace() != 0.
Currently this is the same, PT_PTRACED must be always set if the task is
ptraced.
This change is needed to make sure ptrace_signal() does nothing if ptrace
is implemented on top of utrace, eventually this code will be removed
completely.
Signed-off-by: Roland McGrath <roland@redhat.com>
Signed-off-by: Oleg Nesterov <oleg@redhat.com>
---
kernel/signal.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- V1/kernel/signal.c~10_PTRACE_SIGNAL_CK_PTRACED 2009-11-24 20:29:06.000000000 +0100
+++ V1/kernel/signal.c 2009-11-24 20:30:15.000000000 +0100
@@ -1731,7 +1731,7 @@ static int do_signal_stop(int signr)
static int ptrace_signal(int signr, siginfo_t *info,
struct pt_regs *regs, void *cookie)
{
- if (!task_ptrace(current))
+ if (!(task_ptrace(current) & PT_PTRACED))
return signr;
ptrace_signal_deliver(regs, cookie);
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2009-11-24 20:07 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-11-24 20:02 [RFC,PATCH 10/14] ptrace_signal: check PT_PTRACED before reporting a signal Oleg Nesterov
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.