From 71c746d00af93fed64d0daafd8fb5e884f7cc243 Mon Sep 17 00:00:00 2001 From: Mohammed Sohail Date: Mon, 9 Dec 2024 10:08:36 +0300 Subject: [PATCH] fix: call Stop on all other signals to correctly set the server state for the shutdown procedure to complete successfully * possibly fixes: #979 --- signals_unix.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/signals_unix.go b/signals_unix.go index 8bd2fc5..274675f 100644 --- a/signals_unix.go +++ b/signals_unix.go @@ -24,8 +24,10 @@ func (srv *Server) waitForSignals() { if sig == unix.SIGTSTP { srv.Stop() continue + } else { + srv.Stop() + break } - break } }