From: Ilia Mirkin Date: Sun, 13 Mar 2011 05:29:03 +0000 (-0500) Subject: staging: pohmelfs: Remove NULL check before kfree X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=14910178fcdcca53230afd4155a6c48e230b2919;p=linux-beck.git staging: pohmelfs: Remove NULL check before kfree This patch was generated by the following semantic patch: // @@ expression E; @@ - if (E != NULL) { kfree(E); } + kfree(E); @@ expression E; @@ - if (E != NULL) { kfree(E); E = NULL; } + kfree(E); + E = NULL; // Signed-off-by: Ilia Mirkin Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/pohmelfs/config.c b/drivers/staging/pohmelfs/config.c index ed913306e5d6..a9a3e25a7efa 100644 --- a/drivers/staging/pohmelfs/config.c +++ b/drivers/staging/pohmelfs/config.c @@ -601,11 +601,9 @@ void pohmelfs_config_exit(void) list_del(&g->group_entry); - if (g->hash_string) - kfree(g->hash_string); + kfree(g->hash_string); - if (g->cipher_string) - kfree(g->cipher_string); + kfree(g->cipher_string); kfree(g); }