projects
/
profile
/
ivi
/
kernel-x86-ivi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f5fc879
)
HID: zydacron: kfree() NULL pointer cleanup
author
Bojan Prtvar
<prtvar.b@gmail.com>
Thu, 4 Aug 2011 20:43:46 +0000
(22:43 +0200)
committer
Jiri Kosina
<jkosina@suse.cz>
Thu, 4 Aug 2011 21:51:29 +0000
(23:51 +0200)
Checking for NULL pointers before kfree() is redundant.
Signed-off-by: Bojan Prtvar <prtvar.b@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
drivers/hid/hid-zydacron.c
patch
|
blob
|
history
diff --git
a/drivers/hid/hid-zydacron.c
b/drivers/hid/hid-zydacron.c
index
e903715
..
1ad85f2
100644
(file)
--- a/
drivers/hid/hid-zydacron.c
+++ b/
drivers/hid/hid-zydacron.c
@@
-201,9
+201,7
@@
static void zc_remove(struct hid_device *hdev)
struct zc_device *zc = hid_get_drvdata(hdev);
hid_hw_stop(hdev);
-
- if (NULL != zc)
- kfree(zc);
+ kfree(zc);
}
static const struct hid_device_id zc_devices[] = {