ndisc: Use skb_linearize() instead of pskb_may_pull(skb, skb->len).
authorYOSHIFUJI Hideaki / 吉藤英明 <yoshfuji@linux-ipv6.org>
Mon, 21 Jan 2013 06:48:03 +0000 (06:48 +0000)
committerDavid S. Miller <davem@davemloft.net>
Mon, 21 Jan 2013 18:33:14 +0000 (13:33 -0500)
Suggested by Eric Dumazet <edumazet@google.com>.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/ndisc.c

index 82ccf0a43063faf8e105e7c2b79dcf1d915bee19..539b2ec37d3a4b99af849c673ce22601d441817e 100644 (file)
@@ -1509,7 +1509,7 @@ int ndisc_rcv(struct sk_buff *skb)
 {
        struct nd_msg *msg;
 
-       if (!pskb_may_pull(skb, skb->len))
+       if (skb_linearize(skb))
                return 0;
 
        msg = (struct nd_msg *)skb_transport_header(skb);