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()


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Tux-droid-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tux-droid-svn

Reply via email to