diff options
author | brian <brian@cvs.openbsd.org> | 1998-01-20 22:46:33 +0000 |
---|---|---|
committer | brian <brian@cvs.openbsd.org> | 1998-01-20 22:46:33 +0000 |
commit | 3d2201a7982c109e8fc6c5a6a83083f7c0a26303 (patch) | |
tree | 2d37ccc60ab36afd94ca01e70d677e7fcb350e71 /usr.sbin/ppp/ipcp.c | |
parent | 9c88dd386e8011d11f46ffbeec2a412dc2c9edc5 (diff) |
Allow an optional delay when specifying "set openmode active".
The delay defaults to 1 sec (as it always has) unless we've done
a ~p in interactive mode or we've actually detected a HDLC frame.
This is now cleanly implemented (via async timers) so that it is
possible for LCP to come up despite the delay if an LCP REQ is
received.
This will hopefully solve situations with slow servers or slirp
scenarios (where ECHO is left on the port for a second or so before
the peer enters packet mode).
Also, ~p in interactive mode no longer changes the value of the default
openmode delay and -dedicated mode enters packet mode in the right state
according to the value of openmode.
Diffstat (limited to 'usr.sbin/ppp/ipcp.c')
-rw-r--r-- | usr.sbin/ppp/ipcp.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/usr.sbin/ppp/ipcp.c b/usr.sbin/ppp/ipcp.c index f0ba334a9c2..137611fbcdf 100644 --- a/usr.sbin/ppp/ipcp.c +++ b/usr.sbin/ppp/ipcp.c @@ -17,7 +17,7 @@ * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. * - * $Id: ipcp.c,v 1.11 1998/01/18 20:47:20 brian Exp $ + * $Id: ipcp.c,v 1.12 1998/01/20 22:46:25 brian Exp $ * * TODO: * o More RFC1772 backwoard compatibility @@ -84,13 +84,14 @@ struct fsm IpcpFsm = { "IPCP", PROTO_IPCP, IPCP_MAXCODE, - OPEN_ACTIVE, + 0, ST_INITIAL, 0, 0, 0, 0, - {0, 0, 0, NULL, NULL, NULL}, - {0, 0, 0, NULL, NULL, NULL}, + {0, 0, 0, NULL, NULL, NULL}, /* FSM timer */ + {0, 0, 0, NULL, NULL, NULL}, /* Open timer */ + {0, 0, 0, NULL, NULL, NULL}, /* Stopped timer */ LogIPCP, IpcpLayerUp, |