diff --git a/kernel/ptrace.c b/kernel/ptrace.c index 77edad4f0879ee1f505a666b1e55a9d5fe527995..1e99e333b377050bb2bffa4ace0783f5993a3f37 100644 --- a/kernel/ptrace.c +++ b/kernel/ptrace.c @@ -78,9 +78,7 @@ void __ptrace_link(struct task_struct *child, struct task_struct *new_parent, */ static void ptrace_link(struct task_struct *child, struct task_struct *new_parent) { - rcu_read_lock(); - __ptrace_link(child, new_parent, __task_cred(new_parent)); - rcu_read_unlock(); + __ptrace_link(child, new_parent, current_cred()); } /**