Skip to content

Commit

Permalink
Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Browse files Browse the repository at this point in the history
* master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6:
  [PPP]: Fix skbuff.c:BUG due incorrect logic in process_input_packet()
  • Loading branch information
Linus Torvalds committed Apr 23, 2007
2 parents 0f85102 + 7c5050e commit 36e82df
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/net/ppp_async.c
Original file line number Diff line number Diff line change
Expand Up @@ -802,9 +802,9 @@ process_input_packet(struct asyncppp *ap)

/* check for address/control and protocol compression */
p = skb->data;
if (p[0] == PPP_ALLSTATIONS && p[1] == PPP_UI) {
if (p[0] == PPP_ALLSTATIONS) {
/* chop off address/control */
if (skb->len < 3)
if (p[1] != PPP_UI || skb->len < 3)
goto err;
p = skb_pull(skb, 2);
}
Expand Down

0 comments on commit 36e82df

Please sign in to comment.