mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-08-31 10:31:33 -04:00
smb: client: remove redundant NULL check before kfree()
kfree() safely handles NULL pointers, so the explicit NULL check before calling kfree() is unnecessary. This issue was reported by ifnullfree.cocci. Signed-off-by: Mohammad Shahid <mdshahid03@gmail.com> Signed-off-by: Paulo Alcantara <pc@manguebit.org>
This commit is contained in:
committed by
Paulo Alcantara
parent
ba22f575de
commit
019716ca26
@@ -133,8 +133,7 @@ static int cifs_set_compression_by_path(unsigned int xid, struct file *filep,
|
||||
|
||||
close:
|
||||
server->ops->close(xid, tcon, &fid);
|
||||
if (tmp_cfile)
|
||||
kfree(tmp_cfile);
|
||||
kfree(tmp_cfile);
|
||||
cifs_free_open_info(&data);
|
||||
out:
|
||||
free_dentry_path(page);
|
||||
|
||||
Reference in New Issue
Block a user