X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;f=net%2Fipv6%2Ftunnel6.c;h=0ef9a35798d13915eb158e54ee58800ca058168a;hb=8c8a0eab988c94294adbbb4fe955bba7d8ebddcf;hp=5659b52284bd55518960460d49a391a6f5ee8dac;hpb=064c94f9da8845f12446ab37142aa10f3c6f66ac;p=powerpc.git diff --git a/net/ipv6/tunnel6.c b/net/ipv6/tunnel6.c index 5659b52284..0ef9a35798 100644 --- a/net/ipv6/tunnel6.c +++ b/net/ipv6/tunnel6.c @@ -19,11 +19,13 @@ * YOSHIFUJI Hideaki */ +#include #include #include #include #include #include +#include #include #include @@ -87,10 +89,16 @@ static int tunnel6_rcv(struct sk_buff **pskb) struct sk_buff *skb = *pskb; struct xfrm6_tunnel *handler; + if (!pskb_may_pull(skb, sizeof(struct ipv6hdr))) + goto drop; + for (handler = tunnel6_handlers; handler; handler = handler->next) if (!handler->handler(skb)) return 0; + icmpv6_send(skb, ICMPV6_DEST_UNREACH, ICMPV6_PORT_UNREACH, 0, skb->dev); + +drop: kfree_skb(skb); return 0; }