提交 3b69a4c9 编写于 作者: Y Yang Yingliang 提交者: David S. Miller

act_police: remove unnecessary null pointer check

It already has a NULL pointer check of rtab in qdisc_put_rtab().
Remove the check outside of qdisc_put_rtab().
Signed-off-by: NYang Yingliang <yangyingliang@huawei.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 d2adcaa8
......@@ -261,9 +261,7 @@ static int tcf_act_police_locate(struct net *net, struct nlattr *nla,
failure_unlock:
spin_unlock_bh(&police->tcf_lock);
failure:
if (P_tab)
qdisc_put_rtab(P_tab);
if (R_tab)
qdisc_put_rtab(R_tab);
if (ret == ACT_P_CREATED)
kfree(police);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册