Browse Source

PPP, CCP: Fix ccp_cilen returning size if both deflate_correct and deflate_draft are enabled

This fixes a bug returning 4 byte less than necessary for the addci buffer
if both deflate_correct and deflate_draft are enabled.
STABLE-2_1_x
Sylvain Rochet 11 years ago
parent
commit
c49fc8db72
  1. 3
      src/netif/ppp/ccp.c

3
src/netif/ppp/ccp.c

@ -666,7 +666,8 @@ static int ccp_cilen(fsm *f) {
ccp_options *go = &pcb->ccp_gotoptions;
return (go->bsd_compress? CILEN_BSD_COMPRESS: 0)
+ (go->deflate? CILEN_DEFLATE: 0)
+ (go->deflate && go->deflate_correct? CILEN_DEFLATE: 0)
+ (go->deflate && go->deflate_draft? CILEN_DEFLATE: 0)
+ (go->predictor_1? CILEN_PREDICTOR_1: 0)
+ (go->predictor_2? CILEN_PREDICTOR_2: 0)
+ (go->mppe? CILEN_MPPE: 0);

Loading…
Cancel
Save