summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabian Frederick <fabf@skynet.be>2014-06-28 16:18:52 +0400
committerJohn W. Linville <linville@tuxdriver.com>2014-07-01 22:26:26 +0400
commitf528f664d61cdb87fe12eb24ed9b05548a3e71b3 (patch)
treea566c4f88030a56f76d46d94e274bb6b29ccd14b
parent50591c60a93ad3a8d13833cb8048b02d3c2c4bd4 (diff)
downloadlinux-f528f664d61cdb87fe12eb24ed9b05548a3e71b3.tar.xz
drivers/net/wireless/ipw2x00/libipw_module.c: remove unnecessary null test before kfree
Fix checkpatch warning: WARNING: kfree(NULL) is safe this check is probably not required Cc: Stanislav Yakovlev <stas.yakovlev@gmail.com> Cc: "John W. Linville" <linville@tuxdriver.com> Cc: linux-wireless@vger.kernel.org Signed-off-by: Fabian Frederick <fabf@skynet.be> Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r--drivers/net/wireless/ipw2x00/libipw_module.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/wireless/ipw2x00/libipw_module.c b/drivers/net/wireless/ipw2x00/libipw_module.c
index 3adb24021a28..5f31b72a4921 100644
--- a/drivers/net/wireless/ipw2x00/libipw_module.c
+++ b/drivers/net/wireless/ipw2x00/libipw_module.c
@@ -100,8 +100,7 @@ static inline void libipw_networks_free(struct libipw_device *ieee)
int i;
for (i = 0; i < MAX_NETWORK_COUNT; i++) {
- if (ieee->networks[i]->ibss_dfs)
- kfree(ieee->networks[i]->ibss_dfs);
+ kfree(ieee->networks[i]->ibss_dfs);
kfree(ieee->networks[i]);
}
}