From 14a52d90ffd06209555c18b684cc3f4621276779 Mon Sep 17 00:00:00 2001 From: Martin Mares Date: Mon, 17 Feb 2025 18:24:13 +0100 Subject: [PATCH] Fix server crash when a connected at a wrong moment --- server/subauthd.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/server/subauthd.c b/server/subauthd.c index 31753c9..211ec09 100644 --- a/server/subauthd.c +++ b/server/subauthd.c @@ -207,7 +207,9 @@ static int socket_read_handler(struct main_file *fi) file_chg(fi); received_packet(c, packet_buffer, len); - return HOOK_RETRY; + + // This has to be HOOK_IDLE, since the connection may have been already gone. + return HOOK_IDLE; } static int listen_read_handler(struct main_file *fi) -- 2.39.5