提交 1f09f974 编写于 作者: O Oleg Nesterov 提交者: Linus Torvalds

[PATCH] release_task: replace open-coded ptrace_unlink()

Use ptrace_unlink() instead of open-coding.  No changes in kernel/exit.o
Signed-off-by: NOleg Nesterov <oleg@tv-sign.ru>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Signed-off-by: NAndrew Morton <akpm@osdl.org>
Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
上级 8292d633
......@@ -68,13 +68,12 @@ void release_task(struct task_struct * p)
task_t *leader;
struct dentry *proc_dentry;
repeat:
repeat:
atomic_dec(&p->user->processes);
spin_lock(&p->proc_lock);
proc_dentry = proc_pid_unhash(p);
write_lock_irq(&tasklist_lock);
if (unlikely(p->ptrace))
__ptrace_unlink(p);
ptrace_unlink(p);
BUG_ON(!list_empty(&p->ptrace_list) || !list_empty(&p->ptrace_children));
__exit_signal(p);
/*
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册