summaryrefslogtreecommitdiff
path: root/net/userppp/patches/patch-an
blob: 11eb48a4a4bb9f92761288cea299b88e0455bb12 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
$NetBSD: patch-an,v 1.1 2003/06/08 10:36:18 abs Exp $

--- ppp/ipcp.c.orig	Sun Jun  8 11:29:03 2003
+++ ppp/ipcp.c
@@ -1194,8 +1194,7 @@ IpcpDecodeConfig(struct fsm *fp, u_char 
 	    break;
 	  case 6:		/* RFC1332 */
 	    if (ntohs(pcomp->proto) == PROTO_VJCOMP) {
-              if (pcomp->slots <= MAX_VJ_STATES
-                  && pcomp->slots >= MIN_VJ_STATES) {
+              if (pcomp->slots >= MIN_VJ_STATES) {
                 /* Ok, we can do that */
 	        ipcp->peer_compproto = compproto;
 	        ipcp->heis1172 = 0;
@@ -1230,9 +1229,7 @@ IpcpDecodeConfig(struct fsm *fp, u_char 
 
       case MODE_NAK:
 	if (ntohs(pcomp->proto) == PROTO_VJCOMP) {
-          if (pcomp->slots > MAX_VJ_STATES)
-            pcomp->slots = MAX_VJ_STATES;
-          else if (pcomp->slots < MIN_VJ_STATES)
+          if (pcomp->slots < MIN_VJ_STATES)
             pcomp->slots = MIN_VJ_STATES;
           compproto = (ntohs(pcomp->proto) << 16) + (pcomp->slots << 8) +
                       pcomp->compcid;