]> git.baikalelectronics.ru Git - kernel.git/commit
[PATCH] memory leak in dentry_open()
authorPeter Staubach <staubach@redhat.com>
Mon, 7 Nov 2005 08:59:42 +0000 (00:59 -0800)
committerLinus Torvalds <torvalds@g5.osdl.org>
Mon, 7 Nov 2005 15:53:39 +0000 (07:53 -0800)
commit5f60944a007a3364ba148d151b628e215d5acea3
tree957c0a2c2c273f6f13d8b9f95412f71856b5d449
parentaef9378cfbe2f89a951d82fd09000895164aeddc
[PATCH] memory leak in dentry_open()

There is a memory leak possible in dentry_open().  If get_empty_filp()
fails, then the references to dentry and mnt need to be released.  The
attached patch adds the calls to dput() and mntput() to release these two
references.

Signed-off-by: Peter Staubach <staubach@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
fs/open.c