From: Nick Porter Date: Thu, 25 Jun 2026 15:41:43 +0000 (+0100) Subject: Set last_write_success when a connection becomes connected X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9a73c97b764ec175456c993a580ff8bc6d3da034;p=thirdparty%2Ffreeradius-server.git Set last_write_success when a connection becomes connected To give a base time that idle timeouts can be calculated from. --- diff --git a/src/lib/server/trunk.c b/src/lib/server/trunk.c index 918aed5a182..1acce256acd 100644 --- a/src/lib/server/trunk.c +++ b/src/lib/server/trunk.c @@ -3537,6 +3537,13 @@ static void _trunk_connection_on_connected(UNUSED connection_t *conn, */ trunk->pub.last_connected = fr_time(); + /* + * Set last_write_success so that idle timeout checks will run + * from when the connection has connected if they fire before + * any requests are written, rather than from server start time. + */ + tconn->pub.last_write_success = fr_time(); + /* * Insert a timer to reconnect the * connection periodically.