提交 91744f65 编写于 作者: W Wei Yongjun 提交者: David S. Miller

netlink: remove some pointless conditionals before kfree_skb()

Remove some pointless conditionals before kfree_skb().
Signed-off-by: NWei Yongjun <yjwei@cn.fujitsu.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 40d44446
...@@ -1049,7 +1049,6 @@ int netlink_broadcast(struct sock *ssk, struct sk_buff *skb, u32 pid, ...@@ -1049,7 +1049,6 @@ int netlink_broadcast(struct sock *ssk, struct sk_buff *skb, u32 pid,
netlink_unlock_table(); netlink_unlock_table();
if (info.skb2)
kfree_skb(info.skb2); kfree_skb(info.skb2);
if (info.delivery_failure) if (info.delivery_failure)
...@@ -1542,7 +1541,6 @@ EXPORT_SYMBOL(netlink_set_nonroot); ...@@ -1542,7 +1541,6 @@ EXPORT_SYMBOL(netlink_set_nonroot);
static void netlink_destroy_callback(struct netlink_callback *cb) static void netlink_destroy_callback(struct netlink_callback *cb)
{ {
if (cb->skb)
kfree_skb(cb->skb); kfree_skb(cb->skb);
kfree(cb); kfree(cb);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册