Commit 18fcf49f authored by WANG Cong's avatar WANG Cong Committed by David S. Miller

net_sched: fix a memory leak in tc action

Fixes: ddf97ccd ("net_sched: add network namespace support for tc actions")
Reported-by: default avatarDmitry Vyukov <dvyukov@google.com>
Tested-by: default avatarDmitry Vyukov <dvyukov@google.com>
Cc: Jamal Hadi Salim <jhs@mojatatu.com>
Signed-off-by: default avatarCong Wang <xiyou.wangcong@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 138d6153
...@@ -135,6 +135,7 @@ void tcf_hashinfo_destroy(const struct tc_action_ops *ops, ...@@ -135,6 +135,7 @@ void tcf_hashinfo_destroy(const struct tc_action_ops *ops,
static inline void tc_action_net_exit(struct tc_action_net *tn) static inline void tc_action_net_exit(struct tc_action_net *tn)
{ {
tcf_hashinfo_destroy(tn->ops, tn->hinfo); tcf_hashinfo_destroy(tn->ops, tn->hinfo);
kfree(tn->hinfo);
} }
int tcf_generic_walker(struct tc_action_net *tn, struct sk_buff *skb, int tcf_generic_walker(struct tc_action_net *tn, struct sk_buff *skb,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment