From: Jeff Layton Date: Wed, 16 Jun 2010 17:40:17 +0000 (-0400) Subject: cifs: don't call cifs_new_fileinfo unless cifs_open succeeds X-Git-Tag: v2.6.35-rc4~66^2~2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=47c78b7f40a9931a264e3c9bddccacdf8dfb9a30;p=pandora-kernel.git cifs: don't call cifs_new_fileinfo unless cifs_open succeeds It's currently possible for cifs_open to fail after it has already called cifs_new_fileinfo. In that situation, the new fileinfo will be leaked as the caller doesn't call fput. That in turn leads to a busy inodes after umount problem since the fileinfo holds an extra inode reference now. Shuffle cifs_open around a bit so that it only calls cifs_new_fileinfo if it's going to succeed. Signed-off-by: Jeff Layton Reviewed-and-Tested-by: Suresh Jayaraman --- Reading git-diff-tree failed