summaryrefslogtreecommitdiff
path: root/serverloop.c
diff options
context:
space:
mode:
authordjm@openbsd.org <djm@openbsd.org>2020-07-03 06:29:57 +0000
committerDamien Miller <djm@mindrot.org>2020-07-03 17:03:53 +1000
commit183c4aaef944af3a1a909ffa01058c65bac55748 (patch)
tree56fc72b94c86be35deb110d5ec762bee5bb79df3 /serverloop.c
parent6fcfd303d67f16695198cf23d109a988e40eefb6 (diff)
upstream: start ClientAliveInterval bookkeeping before first pass
through select() loop; fixed theoretical case where busy sshd may ignore timeouts from client; inspired by and ok dtucker OpenBSD-Commit-ID: 96bfc4b1f86c7da313882a84755b2b47eb31957f
Diffstat (limited to 'serverloop.c')
-rw-r--r--serverloop.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/serverloop.c b/serverloop.c
index 340b19a5a..48d936d2e 100644
--- a/serverloop.c
+++ b/serverloop.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: serverloop.c,v 1.222 2020/01/30 07:21:38 djm Exp $ */ 1/* $OpenBSD: serverloop.c,v 1.223 2020/07/03 06:29:57 djm Exp $ */
2/* 2/*
3 * Author: Tatu Ylonen <ylo@cs.hut.fi> 3 * Author: Tatu Ylonen <ylo@cs.hut.fi>
4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland 4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -253,6 +253,8 @@ wait_until_can_do_something(struct ssh *ssh,
253 max_time_ms = keepalive_ms; 253 max_time_ms = keepalive_ms;
254 client_alive_scheduled = 1; 254 client_alive_scheduled = 1;
255 } 255 }
256 if (last_client_time == 0)
257 last_client_time = monotime();
256 } 258 }
257 259
258#if 0 260#if 0