cifs: fix filp leak in cifs_atomic_open()
authorMiklos Szeredi <mszeredi@suse.cz>
Mon, 16 Sep 2013 12:51:59 +0000 (14:51 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 1 Oct 2013 16:17:45 +0000 (09:17 -0700)
commitb1bf3479808bfb56cec46edf5dd9f47364715f46
treedf5a3d66f6f9138f21c61d669b2e826b9c83daef
parent22df37406d8f90135b77ec6deb9950b68bcf3f4e
cifs: fix filp leak in cifs_atomic_open()

commit dfb1d61b0e9f9e2c542e9adc8d970689f4114ff6 upstream.

If an error occurs after having called finish_open() then fput() needs to
be called on the already opened file.

Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
Cc: Steve French <sfrench@samba.org>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/cifs/dir.c