diff options
author | Jiri Pirko <jiri@mellanox.com> | 2017-05-22 10:46:13 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-05-22 14:54:16 -0400 |
commit | 2d76b2f8b54abd16225cd80afca36ed43f113c41 (patch) | |
tree | 4bdb6eb967b730de091e58a5fd8635272216c146 | |
parent | 499fde662f1957e3cb8d192a94a099ebe19c714b (diff) |
net: sched: cls_matchall: fix null pointer dereference
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@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | net/sched/cls_matchall.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/net/sched/cls_matchall.c b/net/sched/cls_matchall.c index dee469fed967..51859b8edd7e 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, | |||
203 | 203 | ||
204 | *arg = (unsigned long) head; | 204 | *arg = (unsigned long) head; |
205 | rcu_assign_pointer(tp->root, new); | 205 | rcu_assign_pointer(tp->root, new); |
206 | call_rcu(&head->rcu, mall_destroy_rcu); | ||
207 | return 0; | 206 | return 0; |
208 | 207 | ||
209 | err_replace_hw_filter: | 208 | err_replace_hw_filter: |