Skip to content

Commit

Permalink
fs/jfs: Fix missing error code in lmLogInit()
Browse files Browse the repository at this point in the history
[ Upstream commit 4921093 ]

The error code is missing in this code scenario, add the error code
'-EINVAL' to the return value 'rc.

Eliminate the follow smatch warning:

fs/jfs/jfs_logmgr.c:1327 lmLogInit() warn: missing error code 'rc'.

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
Signed-off-by: Dave Kleikamp <dave.kleikamp@oracle.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
Jiapeng Chong authored and gregkh committed Jul 20, 2021
1 parent 936440f commit 0dab716
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions fs/jfs/jfs_logmgr.c
Expand Up @@ -1324,6 +1324,7 @@ int lmLogInit(struct jfs_log * log)
} else {
if (!uuid_equal(&logsuper->uuid, &log->uuid)) {
jfs_warn("wrong uuid on JFS log device");
rc = -EINVAL;
goto errout20;
}
log->size = le32_to_cpu(logsuper->size);
Expand Down

0 comments on commit 0dab716

Please sign in to comment.