mirror of
https://github.com/clearml/dropbear
synced 2025-06-26 18:17:32 +00:00
Add new monotonic_now() wrapper so that timeouts are unaffected by
system clock changes
This commit is contained in:
@@ -397,8 +397,7 @@ void send_msg_ignore() {
|
||||
static void checktimeouts() {
|
||||
|
||||
time_t now;
|
||||
|
||||
now = time(NULL);
|
||||
now = monotonic_now();
|
||||
|
||||
if (ses.connect_time != 0 && now - ses.connect_time >= AUTH_TIMEOUT) {
|
||||
dropbear_close("Timeout before auth");
|
||||
|
||||
Reference in New Issue
Block a user