fixed bug #36388 (PPP: checksum-only in last pbuf leads to pbuf with zero length)

This commit is contained in:
goldsimon
2012-05-03 19:45:22 +02:00
parent 1dff9aea62
commit fb07a28c99
2 changed files with 5 additions and 1 deletions

View File

@@ -1821,7 +1821,7 @@ pppInProc(PPPControlRx *pcrx, u_char *s, int l)
} else {
struct pbuf *inp;
/* Trim off the checksum. */
if(pcrx->inTail->len >= 2) {
if(pcrx->inTail->len > 2) {
pcrx->inTail->len -= 2;
pcrx->inTail->tot_len = pcrx->inTail->len;