提交 d3351b75 编写于 作者: D David S. Miller

ipv4: Deliver ICMP redirects to sockets too.

And thus, we can remove the ping_err() hack.
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 1de9243b
......@@ -782,13 +782,7 @@ static void icmp_redirect(struct sk_buff *skb)
break;
}
/* Ping wants to see redirects.
* Let's pretend they are errors of sorts... */
if (iph->protocol == IPPROTO_ICMP &&
iph->ihl >= 5 &&
pskb_may_pull(skb, (iph->ihl<<2)+8)) {
ping_err(skb, icmp_hdr(skb)->un.gateway);
}
icmp_socket_deliver(skb, icmp_hdr(skb)->un.gateway);
out:
return;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册