From 22d09bff66973faec7a39fd52343a058e7777165 Mon Sep 17 00:00:00 2001 From: Aliasgar Ginwala Date: Mon, 21 Dec 2015 14:10:21 -0800 Subject: [PATCH] fix:bug-556 noVNC hangs after some time (variable) --- websockify/websocket.py | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/websockify/websocket.py b/websockify/websocket.py index 0f8e25e..cfa47ad 100644 --- a/websockify/websocket.py +++ b/websockify/websocket.py @@ -895,11 +895,14 @@ class WebSocketServer(object): raise self.Terminate() def multiprocessing_SIGCHLD(self, sig, stack): - self.vmsg('Reaping zombies, active child count is %s', len(multiprocessing.active_children())) + # TODO: figure out a way to actually log this information without + # calling `log` in the signal handlers + multiprocessing.active_children() def fallback_SIGCHLD(self, sig, stack): # Reap zombies when using os.fork() (python 2.4) - self.vmsg("Got SIGCHLD, reaping zombies") + # TODO: figure out a way to actually log this information without + # calling `log` in the signal handlers try: result = os.waitpid(-1, os.WNOHANG) while result[0]: @@ -909,11 +912,13 @@ class WebSocketServer(object): pass def do_SIGINT(self, sig, stack): - self.msg("Got SIGINT, exiting") + # TODO: figure out a way to actually log this information without + # calling `log` in the signal handlers self.terminate() def do_SIGTERM(self, sig, stack): - self.msg("Got SIGTERM, exiting") + # TODO: figure out a way to actually log this information without + # calling `log` in the signal handlers self.terminate() def top_new_client(self, startsock, address):