mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-11-06 02:27:15 +00:00
using idle_time_limit from ppp_settings
This commit is contained in:
parent
4e7ce11684
commit
becc306300
@ -1219,7 +1219,7 @@ np_up(unit, proto)
|
|||||||
tlim = (*idle_time_hook)(NULL);
|
tlim = (*idle_time_hook)(NULL);
|
||||||
else
|
else
|
||||||
#endif /* UNUSED */
|
#endif /* UNUSED */
|
||||||
tlim = idle_time_limit;
|
tlim = ppp_settings.idle_time_limit;
|
||||||
if (tlim > 0)
|
if (tlim > 0)
|
||||||
TIMEOUT(check_idle, NULL, tlim);
|
TIMEOUT(check_idle, NULL, tlim);
|
||||||
|
|
||||||
@ -1336,7 +1336,7 @@ check_idle(arg)
|
|||||||
} else {
|
} else {
|
||||||
#endif /* UNUSED */
|
#endif /* UNUSED */
|
||||||
itime = LWIP_MIN(idle.xmit_idle, idle.recv_idle);
|
itime = LWIP_MIN(idle.xmit_idle, idle.recv_idle);
|
||||||
tlim = idle_time_limit - itime;
|
tlim = ppp_settings.idle_time_limit - itime;
|
||||||
#if 0 /* UNUSED */
|
#if 0 /* UNUSED */
|
||||||
}
|
}
|
||||||
#endif /* UNUSED */
|
#endif /* UNUSED */
|
||||||
|
@ -108,9 +108,7 @@ bool demand = 0; /* do dial-on-demand */
|
|||||||
#endif /* DEMAND_SUPPORT */
|
#endif /* DEMAND_SUPPORT */
|
||||||
#if 0
|
#if 0
|
||||||
char *ipparam = NULL; /* Extra parameter for ip up/down scripts */
|
char *ipparam = NULL; /* Extra parameter for ip up/down scripts */
|
||||||
#endif
|
|
||||||
int idle_time_limit = 0; /* Disconnect if idle for this many seconds */
|
int idle_time_limit = 0; /* Disconnect if idle for this many seconds */
|
||||||
#if 0
|
|
||||||
int holdoff = 30; /* # seconds to pause before reconnecting */
|
int holdoff = 30; /* # seconds to pause before reconnecting */
|
||||||
bool holdoff_specified; /* true if a holdoff value has been given */
|
bool holdoff_specified; /* true if a holdoff value has been given */
|
||||||
int log_to_fd = 1; /* send log messages to this fd too */
|
int log_to_fd = 1; /* send log messages to this fd too */
|
||||||
|
@ -434,7 +434,7 @@ struct ppp_settings {
|
|||||||
u_int usepeerdns : 1; /* Ask peer for DNS adds */
|
u_int usepeerdns : 1; /* Ask peer for DNS adds */
|
||||||
u_int persist : 1; /* Persist mode, always try to reopen the connection */
|
u_int persist : 1; /* Persist mode, always try to reopen the connection */
|
||||||
|
|
||||||
u_short idle_time_limit; /* Shut down link if idle for this long */
|
u_short idle_time_limit; /* Disconnect if idle for this many seconds */
|
||||||
int maxconnect; /* Maximum connect time (seconds) */
|
int maxconnect; /* Maximum connect time (seconds) */
|
||||||
|
|
||||||
char user [MAXNAMELEN + 1]; /* Username for PAP */
|
char user [MAXNAMELEN + 1]; /* Username for PAP */
|
||||||
|
Loading…
Reference in New Issue
Block a user