Skip to content

Commit f3fbaa7

Browse files
ordextytso
authored andcommitted
ext4: remove useless if check
This if branch is only jumping to 'out' which is defined just after the branch itself. Hence this is if-check is a no-op and can be removed. Address-Coverity-ID: 1647981 ("Incorrect expression (IDENTICAL_BRANCHES)") Signed-off-by: Antonio Quartulli <antonio@mandelbit.com> Link: https://patch.msgid.link/20250721200902.1071-1-antonio@mandelbit.com Signed-off-by: Theodore Ts'o <tytso@mit.edu>
1 parent b4cc4a4 commit f3fbaa7

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

fs/ext4/namei.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2984,8 +2984,6 @@ int ext4_init_new_dir(handle_t *handle, struct inode *dir,
29842984
return PTR_ERR(dir_block);
29852985
de = (struct ext4_dir_entry_2 *)dir_block->b_data;
29862986
err = ext4_init_dirblock(handle, inode, dir_block, dir->i_ino, NULL, 0);
2987-
if (err)
2988-
goto out;
29892987
out:
29902988
brelse(dir_block);
29912989
return err;

0 commit comments

Comments
 (0)