proc: fix task_struct leak in proc_pid_fd_link_getattr()
In the patch "proc: fix races against execve() of /proc/PID/fd**" proc_pid_fd_link_getattr() leaked task_struct if ptrace check fails.
Signed-off-by Vasiliy Kulikov <[email protected]>
Reported-by Cyrill Gorcunov <[email protected]>
--
fs/proc/base.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
fs/proc/base.c +1 -1
@@ -1681,9 +1681,9 @@ static int proc_pid_fd_link_getattr(struct vfsmount *mnt, struct dentry *dentry,generic_fillattr (inode, stat);unlock_trace (task); -put_task_struct (task); rc =0 ; out_task: +put_task_struct (task);return rc; }
Signature · 1 line
Vasiliy