From f7cfe660cd0e13759a5231638b3dc0a21b8b9dc2 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Tue, 23 Mar 2021 21:46:11 +0100 Subject: mod_c2s: Log a debug message before closing due to c2s_timeout It was confusing that the connection would just close without much explanation. Wanted this while investigating https://github.com/conversejs/converse.js/issues/2438 --- plugins/mod_c2s.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/plugins/mod_c2s.lua b/plugins/mod_c2s.lua index a1820029..878b853d 100644 --- a/plugins/mod_c2s.lua +++ b/plugins/mod_c2s.lua @@ -322,6 +322,7 @@ function listener.onconnect(conn) if c2s_timeout then add_task(c2s_timeout, function () if session.type == "c2s_unauthed" then + (session.log or log)("debug", "Connection still not authenticated after c2s_timeout=%gs, closing it", c2s_timeout); session:close("connection-timeout"); end end); -- cgit v1.2.3