mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
synced 2025-01-10 15:58:47 +00:00
orangefs: don't let orangefs_iget return NULL.
Suggested by Dan Carpenter. Signed-off-by: Mike Marshall <hubcap@omnibond.com>
This commit is contained in:
parent
56249998b2
commit
b5d72cdc53
@ -405,7 +405,11 @@ struct inode *orangefs_iget(struct super_block *sb,
|
||||
orangefs_test_inode,
|
||||
orangefs_set_inode,
|
||||
ref);
|
||||
if (!inode || !(inode->i_state & I_NEW))
|
||||
|
||||
if (!inode)
|
||||
return ERR_PTR(-ENOMEM);
|
||||
|
||||
if (!(inode->i_state & I_NEW))
|
||||
return inode;
|
||||
|
||||
error = orangefs_inode_getattr(inode, 1, 1, STATX_ALL);
|
||||
|
Loading…
x
Reference in New Issue
Block a user