X-Git-Url: http://git.ozlabs.org/?p=ppp.git;a=blobdiff_plain;f=pppd%2Fccp.c;h=a0eb2ad0d2d3da113cb5cdc762b5aa3c59cbf5f8;hp=6f3c1ea52e5687cef1faf865f6a255842d112567;hb=7173a14a57e110a75b316d0ad6de58f2eea5057c;hpb=e99cbc1138211324beaf1d91944624b87eba1518 diff --git a/pppd/ccp.c b/pppd/ccp.c index 6f3c1ea..a0eb2ad 100644 --- a/pppd/ccp.c +++ b/pppd/ccp.c @@ -26,9 +26,10 @@ */ #ifndef lint -static char rcsid[] = "$Id: ccp.c,v 1.15 1996/01/18 03:20:25 paulus Exp $"; +static char rcsid[] = "$Id: ccp.c,v 1.16 1996/04/04 03:35:37 paulus Exp $"; #endif +#include #include #include #include @@ -142,8 +143,15 @@ ccp_open(unit) if (f->state != OPENED) ccp_flags_set(unit, 1, 0); - if (!ANY_COMPRESS(ccp_wantoptions[unit])) + + /* + * Find out which compressors the kernel supports before + * deciding whether to open in silent mode. + */ + ccp_resetci(f); + if (!ANY_COMPRESS(ccp_gotoptions[unit])) f->flags |= OPT_SILENT; + fsm_open(f); } @@ -259,7 +267,6 @@ static void ccp_resetci(f) fsm *f; { - int ok; ccp_options *go = &ccp_gotoptions[f->unit]; u_char opt_buf[16];