[tuxdroid-svn] r5241 - software_suite_v3/smart-core/smart-server/trunk
Status: Beta
Brought to you by:
ks156
|
From: remi <c2m...@c2...> - 2009-07-30 14:28:29
|
Author: remi
Date: 2009-07-30 16:28:11 +0200 (Thu, 30 Jul 2009)
New Revision: 5241
Modified:
software_suite_v3/smart-core/smart-server/trunk/tuxhttpserver.py
Log:
* Updated the server stop method for Windows.
Modified: software_suite_v3/smart-core/smart-server/trunk/tuxhttpserver.py
===================================================================
--- software_suite_v3/smart-core/smart-server/trunk/tuxhttpserver.py 2009-07-30 10:32:13 UTC (rev 5240)
+++ software_suite_v3/smart-core/smart-server/trunk/tuxhttpserver.py 2009-07-30 14:28:11 UTC (rev 5241)
@@ -27,14 +27,15 @@
return URLTestRequestGet("127.0.0.1", TDS_HTTP_PORT, "/", 200, 5.0)
def killServer():
- # Stop the server regularly
- URLTestRequestGet("127.0.0.1", TDS_HTTP_PORT, "/server/stop?", 200, 0.5)
- URLTestRequestGet("127.0.0.1", TDS_HTTP_PORT, "/server/stop?", 200, 0.5)
- # Wait 5 secs max that the previous server has been stopped
- for i in range(10):
- if not checkServerRun():
- break
- time.sleep(0.5)
+ if os.name != 'nt':
+ # Stop the server regularly
+ URLTestRequestGet("127.0.0.1", TDS_HTTP_PORT, "/server/stop?", 200, 0.5)
+ URLTestRequestGet("127.0.0.1", TDS_HTTP_PORT, "/server/stop?", 200, 0.5)
+ # Wait 5 secs max that the previous server has been stopped
+ for i in range(10):
+ if not checkServerRun():
+ break
+ time.sleep(0.5)
# Kill smart-core tasks if still alive
killOldSmartCoreChildren()
killPreviousSmartServer()
|