* [PATCH 1/1] net/netfilter/nf_conntrack_netlink.c: remove null test before kfree
@ 2014-06-20 20:38 Fabian Frederick
2014-06-25 12:56 ` Pablo Neira Ayuso
0 siblings, 1 reply; 2+ messages in thread
From: Fabian Frederick @ 2014-06-20 20:38 UTC (permalink / raw)
To: linux-kernel
Cc: Fabian Frederick, Pablo Neira Ayuso, Patrick McHardy, netfilter-devel
Fix checkpatch warning:
WARNING: kfree(NULL) is safe this check is probably not required
Cc: Pablo Neira Ayuso <pablo@netfilter.org>
Cc: Patrick McHardy <kaber@trash.net>
Cc: netfilter-devel@vger.kernel.org
Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
net/netfilter/nf_conntrack_netlink.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/net/netfilter/nf_conntrack_netlink.c b/net/netfilter/nf_conntrack_netlink.c
index 5857963..aee017f 100644
--- a/net/netfilter/nf_conntrack_netlink.c
+++ b/net/netfilter/nf_conntrack_netlink.c
@@ -742,8 +742,7 @@ static int ctnetlink_done(struct netlink_callback *cb)
{
if (cb->args[1])
nf_ct_put((struct nf_conn *)cb->args[1]);
- if (cb->data)
- kfree(cb->data);
+ kfree(cb->data);
return 0;
}
--
1.8.4.5
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 1/1] net/netfilter/nf_conntrack_netlink.c: remove null test before kfree
2014-06-20 20:38 [PATCH 1/1] net/netfilter/nf_conntrack_netlink.c: remove null test before kfree Fabian Frederick
@ 2014-06-25 12:56 ` Pablo Neira Ayuso
0 siblings, 0 replies; 2+ messages in thread
From: Pablo Neira Ayuso @ 2014-06-25 12:56 UTC (permalink / raw)
To: Fabian Frederick; +Cc: linux-kernel, Patrick McHardy, netfilter-devel
On Fri, Jun 20, 2014 at 10:38:58PM +0200, Fabian Frederick wrote:
> Fix checkpatch warning:
> WARNING: kfree(NULL) is safe this check is probably not required
Applied, thanks.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-06-25 12:56 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-06-20 20:38 [PATCH 1/1] net/netfilter/nf_conntrack_netlink.c: remove null test before kfree Fabian Frederick
2014-06-25 12:56 ` Pablo Neira Ayuso
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).