f2fs: dereferencing an ERR_PTR
There is an error path where "dir" is an ERR_PTR. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>
This commit is contained in:
parent
6f6fd833e1
commit
f28c06fa6f
|
@ -71,7 +71,8 @@ static int recover_dentry(struct page *ipage, struct inode *inode)
|
|||
out:
|
||||
f2fs_msg(inode->i_sb, KERN_NOTICE, "recover_inode and its dentry: "
|
||||
"ino = %x, name = %s, dir = %lx, err = %d",
|
||||
ino_of_node(ipage), raw_inode->i_name, dir->i_ino, err);
|
||||
ino_of_node(ipage), raw_inode->i_name,
|
||||
IS_ERR(dir) ? 0 : dir->i_ino, err);
|
||||
return err;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue