Author: chrisz
Date: Fri Oct 10 05:58:26 2008
New Revision: 7543
Modified:
Webware/trunk/WebKit/AppServerService.py
Log:
Reset sys.stdout and sys.stderr before shutting down AppServerService to avoid errors when somebody redirected or reset these with reload(sys) (this is issue #2124553 reported by by Oleg Noga).
Modified: Webware/trunk/WebKit/AppServerService.py
==============================================================================
--- Webware/trunk/WebKit/AppServerService.py (original)
+++ Webware/trunk/WebKit/AppServerService.py Fri Oct 10 05:58:26 2008
@@ -222,6 +222,7 @@
Profiler.runCall(self._server.mainloop)
else:
self._server.mainloop()
+ sys.stdout = sys.stderr = log # in case this has been reset
print
sys.stdout.flush()
if self._server._running:
|