From 043dcfbf5663eedf82c86b17274099c6ff62f91c Mon Sep 17 00:00:00 2001 From: Mohamed Sohail Date: Wed, 11 Dec 2024 09:05:00 +0300 Subject: [PATCH] fix: call Stop on all other signals to correctly set the server state for the shutdown procedure to complete successfully (#982) * 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 } }