Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ericvh/v9fs
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ericvh/v9fs: 9p: potential ERR_PTR() dereference
This commit is contained in:
commit
3c5dff7b5e
1 changed files with 2 additions and 1 deletions
|
@ -242,7 +242,8 @@ struct p9_fid *v9fs_fid_lookup(struct dentry *dentry)
|
|||
}
|
||||
kfree(wnames);
|
||||
fid_out:
|
||||
v9fs_fid_add(dentry, fid);
|
||||
if (!IS_ERR(fid))
|
||||
v9fs_fid_add(dentry, fid);
|
||||
err_out:
|
||||
up_read(&v9ses->rename_sem);
|
||||
return fid;
|
||||
|
|
Loading…
Reference in a new issue