[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20170522144613.22848-1-jiri@resnulli.us>
Date: Mon, 22 May 2017 16:46:13 +0200
From: Jiri Pirko <jiri@...nulli.us>
To: netdev@...r.kernel.org
Cc: davem@...emloft.net, jhs@...atatu.com, xiyou.wangcong@...il.com,
mlxsw@...lanox.com, colin.king@...onical.com, yotamg@...lanox.com
Subject: [patch net-next] net: sched: cls_matchall: fix null pointer dereference
From: Jiri Pirko <jiri@...lanox.com>
Since the head is guaranteed by the check above to be null, the call_rcu
would explode. Remove the previously logically dead code that was made
logically very much alive and kicking.
Fixes: 985538eee06f ("net/sched: remove redundant null check on head")
Signed-off-by: Jiri Pirko <jiri@...lanox.com>
---
net/sched/cls_matchall.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/net/sched/cls_matchall.c b/net/sched/cls_matchall.c
index dee469f..51859b8 100644
--- a/net/sched/cls_matchall.c
+++ b/net/sched/cls_matchall.c
@@ -203,7 +203,6 @@ static int mall_change(struct net *net, struct sk_buff *in_skb,
*arg = (unsigned long) head;
rcu_assign_pointer(tp->root, new);
- call_rcu(&head->rcu, mall_destroy_rcu);
return 0;
err_replace_hw_filter:
--
2.9.3
Powered by blists - more mailing lists