diff options
| author | 2015-10-14 07:29:19 +0530 | |
|---|---|---|
| committer | 2015-10-16 21:31:25 -0700 | |
| commit | 95f840fb5355eda0bf797a2d7b6e684127128cac (patch) | |
| tree | 6c3f2483b15f44931828a986a2ef87a250dc634c /scripts | |
| parent | Staging: wilc1000: host_interface: Remove unnecessary enum (diff) | |
Staging: wilc1000: Remove null check before kfree
kfree on NULL pointer is a no-op.
The semantic patch used 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>
Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions
