diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2013-05-23 14:02:13 +0400 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk.kim@samsung.com> | 2013-05-28 10:03:04 +0400 |
commit | f28c06fa6f3d3215a1ba5e62ebc5ce7229d7a895 (patch) | |
tree | 7e8030953c012b9c53a6476acaef7e44c7018034 /fs/f2fs | |
parent | 6f6fd833e1857e79a363fb20497237367bcfb7ee (diff) | |
download | linux-f28c06fa6f3d3215a1ba5e62ebc5ce7229d7a895.tar.xz |
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>
Diffstat (limited to 'fs/f2fs')
-rw-r--r-- | fs/f2fs/recovery.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/f2fs/recovery.c b/fs/f2fs/recovery.c index dcd8e860aad3..0dd2ce1b492f 100644 --- a/fs/f2fs/recovery.c +++ b/fs/f2fs/recovery.c @@ -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; } |