diff options
Diffstat (limited to 'drivers/net/pppoe.c')
-rw-r--r-- | drivers/net/pppoe.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/pppoe.c b/drivers/net/pppoe.c index d89ccfd6650c..bafb69b6f7cb 100644 --- a/drivers/net/pppoe.c +++ b/drivers/net/pppoe.c | |||
@@ -432,12 +432,12 @@ static int pppoe_disc_rcv(struct sk_buff *skb, | |||
432 | if (dev_net(dev) != &init_net) | 432 | if (dev_net(dev) != &init_net) |
433 | goto abort; | 433 | goto abort; |
434 | 434 | ||
435 | if (!pskb_may_pull(skb, sizeof(struct pppoe_hdr))) | ||
436 | goto abort; | ||
437 | |||
438 | if (!(skb = skb_share_check(skb, GFP_ATOMIC))) | 435 | if (!(skb = skb_share_check(skb, GFP_ATOMIC))) |
439 | goto out; | 436 | goto out; |
440 | 437 | ||
438 | if (!pskb_may_pull(skb, sizeof(struct pppoe_hdr))) | ||
439 | goto abort; | ||
440 | |||
441 | ph = pppoe_hdr(skb); | 441 | ph = pppoe_hdr(skb); |
442 | if (ph->code != PADT_CODE) | 442 | if (ph->code != PADT_CODE) |
443 | goto abort; | 443 | goto abort; |