Message ID | 1353408838-28678-1-git-send-email-sachin.kamat@linaro.org |
---|---|
State | Accepted, archived |
Delegated to: | David Miller |
Headers | show |
> kfree on a null pointer is a no-op. > > Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Acked-by: Sjur Brændeland <sjur.brandeland@stericsson.com> -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
From: Sjur BRENDELAND <sjur.brandeland@stericsson.com> Date: Tue, 20 Nov 2012 12:04:23 +0100 >> kfree on a null pointer is a no-op. >> >> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> > Acked-by: Sjur Brændeland <sjur.brandeland@stericsson.com> Applied. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/net/caif/cfctrl.c b/net/caif/cfctrl.c index 44f270f..a376ec1 100644 --- a/net/caif/cfctrl.c +++ b/net/caif/cfctrl.c @@ -515,8 +515,7 @@ static int cfctrl_recv(struct cflayer *layer, struct cfpkt *pkt) client_layer : NULL); } - if (req != NULL) - kfree(req); + kfree(req); spin_unlock_bh(&cfctrl->info_list_lock); }
kfree on a null pointer is a no-op. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> --- net/caif/cfctrl.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-)