Release the helper object and the expect_policy.

Signed-off-by: Pablo Neira Ayuso <pa...@netfilter.org>
---
 net/netfilter/nfnetlink_cthelper.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/net/netfilter/nfnetlink_cthelper.c 
b/net/netfilter/nfnetlink_cthelper.c
index 3166406d68d3..2defe730b1f4 100644
--- a/net/netfilter/nfnetlink_cthelper.c
+++ b/net/netfilter/nfnetlink_cthelper.c
@@ -609,6 +609,8 @@ static int nfnl_cthelper_del(struct net *net, struct sock 
*nfnl,
 
                        found = true;
                        nf_conntrack_helper_unregister(cur);
+                       kfree(cur->expect_policy);
+                       kfree(cur);
                }
        }
        /* Make sure we return success if we flush and there is no helpers */
-- 
2.1.4

--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to