Skip to content

Commit

Permalink
jfs: Deletion of an unnecessary check before the function call "unloa…
Browse files Browse the repository at this point in the history
…d_nls"

The unload_nls() function tests whether its argument is NULL and then
returns immediately. Thus the test around the call is not needed.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <[email protected]>
Signed-off-by: Dave Kleikamp <[email protected]>
  • Loading branch information
elfring authored and kleikamp committed Feb 2, 2015
1 parent e1f1fe7 commit 648695c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions fs/jfs/super.c
Original file line number Diff line number Diff line change
Expand Up @@ -619,8 +619,7 @@ static int jfs_fill_super(struct super_block *sb, void *data, int silent)
iput(sbi->direct_inode);
sbi->direct_inode = NULL;
out_unload:
if (sbi->nls_tab)
unload_nls(sbi->nls_tab);
unload_nls(sbi->nls_tab);
out_kfree:
kfree(sbi);
return ret;
Expand Down

0 comments on commit 648695c

Please sign in to comment.