if not configParams.server_only:
try:
server_connection = server.establishConnection(featureset)
- server_connection.setupEventQueue()
except Exception as e:
bb.fatal("Could not connect to server %s: %s" % (configParams.remote_server, str(e)))
+ if configParams.kill_server:
+ server_connection.connection.terminateServer()
+ bb.event.ui_queue = []
+ return 0
+
+ server_connection.setupEventQueue()
+
# Restore the environment in case the UI needs it
for k in cleanedvars:
os.environ[k] = cleanedvars[k]
server_connection.terminate()
return 0
- if configParams.kill_server:
- server_connection.connection.terminateServer()
- bb.event.ui_queue = []
- return 0
-
try:
return ui_module.main(server_connection.connection, server_connection.events, configParams)
finally: