mfd: viperboard: 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>
Link: https://patch.msgid.link/20260703105937.62541-1-mdshahid03@gmail.com
Signed-off-by: Lee Jones <lee@kernel.org>
This commit is contained in:
Mohammad Shahid 2026-07-03 16:29:37 +05:30 committed by Lee Jones
parent 0f2da45318
commit 733fbd0d11

View File

@ -96,8 +96,7 @@ static int vprbrd_probe(struct usb_interface *interface,
return 0;
error:
if (vb)
kfree(vb);
kfree(vb);
return ret;
}