提交 9856af8b 编写于 作者: A Aneesh Kumar K.V 提交者: Eric Van Hensbergen

fs/9p: Add missing iput in v9fs_vfs_lookup

Make sure we drop inode reference in the error path
Signed-off-by: NAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: NVenkateswararao Jujjuri <jvrao@linux.vnet.ibm.com>
Signed-off-by: NEric Van Hensbergen <ericvh@gmail.com>
上级 f5fc6145
......@@ -1037,7 +1037,7 @@ static struct dentry *v9fs_vfs_lookup(struct inode *dir, struct dentry *dentry,
result = v9fs_fid_add(dentry, fid);
if (result < 0)
goto error;
goto error_iput;
inst_out:
if (v9ses->cache)
......@@ -1048,6 +1048,8 @@ static struct dentry *v9fs_vfs_lookup(struct inode *dir, struct dentry *dentry,
d_add(dentry, inode);
return NULL;
error_iput:
iput(inode);
error:
p9_client_clunk(fid);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册