From e0ae527190ab2d7aa6d58cd50abbcde8ef32df8c Mon Sep 17 00:00:00 2001 From: Matt Johnston Date: Tue, 17 Nov 2015 20:53:30 +0800 Subject: Only clear channel_signal_pending after handling all channels, from Andrzej Szombierski --- common-channel.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/common-channel.c b/common-channel.c index abe5941..b846f28 100644 --- a/common-channel.c +++ b/common-channel.c @@ -256,7 +256,6 @@ void channelio(fd_set *readfds, fd_set *writefds) { if (ses.channel_signal_pending) { /* SIGCHLD can change channel state for server sessions */ do_check_close = 1; - ses.channel_signal_pending = 0; } /* handle any channel closing etc */ @@ -265,6 +264,8 @@ void channelio(fd_set *readfds, fd_set *writefds) { } } + ses.channel_signal_pending = 0; + #ifdef USING_LISTENERS handle_listeners(readfds); #endif -- cgit v1.2.3