Subject: "pppd" should unset connect-time timer on disconnect
To: Christos Zoulas <>
From: Frederick Bruckman <>
List: tech-userlevel
Date: 07/10/2002 09:48:57

The following (or something like it) is needed to prevent "random"
disconnects when using both "demand" and "max-connect NNN". [Many
ISP's now require/enforce max-connect, unless you pay extra for a
dedicated line.] The disconnects aren't really random; rather, they're
"max-connect" time since some previous connect, but really, only the
latest disconnect timer should count. I've been running with this for
a long time on NetBSD 1.5.2, and I've just merged to the head and
verified that it still builds. Is it OK if I commit?

Index: auth.c
RCS file: /cvsroot/basesrc/usr.sbin/pppd/pppd/auth.c,v
retrieving revision 1.29
diff -c -r1.29 auth.c
*** auth.c	2002/07/01 22:19:30	1.29
--- auth.c	2002/07/10 14:15:09
*** 762,767 ****
--- 762,768 ----
      if (--num_np_up == 0) {
  	UNTIMEOUT(check_idle, NULL);
+ 	UNTIMEOUT(connect_time_expired, NULL);