]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
Merge branch 'tracehook' of git://git.kernel.org/pub/scm/linux/kernel/git/frob/linux...
authorLinus Torvalds <torvalds@linux-foundation.org>
Fri, 8 Aug 2008 01:14:24 +0000 (18:14 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 8 Aug 2008 01:14:24 +0000 (18:14 -0700)
* 'tracehook' of git://git.kernel.org/pub/scm/linux/kernel/git/frob/linux-2.6-utrace:
  tracehook: fix CLONE_PTRACE

include/linux/ptrace.h
include/linux/tracehook.h

index fd31756e1a00f632189022dec352a49fe525ac62..ea7416c901d1ef8923adb2417b236cf8633a09f0 100644 (file)
@@ -172,7 +172,7 @@ static inline void ptrace_init_task(struct task_struct *child, bool ptrace)
        child->ptrace = 0;
        if (unlikely(ptrace)) {
                child->ptrace = current->ptrace;
-               __ptrace_link(child, current->parent);
+               ptrace_link(child, current->parent);
        }
 }
 
index ab3ef7aefa9593dcfcf3f531666eba2c1c8f2a2f..b48d8196957436284c429e1d196c434459d8f0be 100644 (file)
@@ -280,7 +280,7 @@ static inline void tracehook_report_clone(int trace, struct pt_regs *regs,
                                          unsigned long clone_flags,
                                          pid_t pid, struct task_struct *child)
 {
-       if (unlikely(trace)) {
+       if (unlikely(trace) || unlikely(clone_flags & CLONE_PTRACE)) {
                /*
                 * The child starts up with an immediate SIGSTOP.
                 */