linux/drivers/staging/rtl8188eu
Tapasweni Pathak a055b3cbb7 staging: rtl8188eu: core: Remove null check before kfree
kfree on NULL pointer is a no-op.

This patch uses the following semantic patch to find such an instance
where NULL check is present before kfree.

// <smpl>
@@ expression E; @@
- if (E != NULL) { kfree(E); }
+ kfree(E);
@@ expression E; @@
- if (E != NULL) { kfree(E); E = NULL; }
+ kfree(E);
+ E = NULL;
// </smpl>smpl>

Build tested it.

Signed-off-by: Tapasweni Pathak <tapaswenipathak@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-10-30 13:12:05 -07:00
..
core staging: rtl8188eu: core: Remove null check before kfree 2014-10-30 13:12:05 -07:00
hal staging: rtl8188eu: hal: Remove useless cast on void pointer 2014-10-30 13:05:49 -07:00
include Staging: rtl8188eu: include: Remove unused macros 2014-10-20 10:29:12 +08:00
os_dep staging: rtl8188eu: os_dep: Remove useless cast on void pointer 2014-10-30 13:05:49 -07:00
Kconfig staging: rtl8188eu: Remove P2P support 2014-07-09 21:08:47 -07:00
Makefile staging: rtl8188eu: Remove odm_debug.c 2014-09-23 23:47:12 -07:00
TODO staging: Additional item for rtl8188eu TODO list 2014-02-14 09:19:53 -08:00