diff options
author | Oleg Nesterov <oleg@redhat.com> | 2014-12-10 15:54:56 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-12-10 17:41:17 -0800 |
commit | c35a7f18a0b237261dad57c9abd3adfa73f315e1 (patch) | |
tree | ed31c75a45ffe68305833eb9c93257b209631886 /fs/proc | |
parent | 26e75b5c3d2226cb995fde064744aa93f63849c4 (diff) | |
download | blackbird-obmc-linux-c35a7f18a0b237261dad57c9abd3adfa73f315e1.tar.gz blackbird-obmc-linux-c35a7f18a0b237261dad57c9abd3adfa73f315e1.zip |
exit: proc: don't try to flush /proc/tgid/task/tgid
proc_flush_task_mnt() always tries to flush task/pid, but this is
pointless if we reap the leader. d_invalidate() is recursive, and
if nothing else the next d_hash_and_lookup(tgid) should fail anyway.
Signed-off-by: Oleg Nesterov <oleg@redhat.com>
Cc: Aaron Tomlin <atomlin@redhat.com>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: Rik van Riel <riel@redhat.com>
Cc: Sterling Alexander <stalexan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/proc')
-rw-r--r-- | fs/proc/base.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/proc/base.c b/fs/proc/base.c index 772efa45a452..e7b04a321cc1 100644 --- a/fs/proc/base.c +++ b/fs/proc/base.c @@ -2618,6 +2618,9 @@ static void proc_flush_task_mnt(struct vfsmount *mnt, pid_t pid, pid_t tgid) dput(dentry); } + if (pid == tgid) + return; + name.name = buf; name.len = snprintf(buf, sizeof(buf), "%d", tgid); leader = d_hash_and_lookup(mnt->mnt_root, &name); |