Global name standalone not defined (#1030). Correct only the error message at the end of Glances but not the main cause of the issue (Webserver interface is not displayed)

This commit is contained in:
nicolargo 2017-02-10 22:24:19 +01:00
parent a4238443ac
commit 907856a941

View File

@ -70,11 +70,11 @@ def __signal_handler(signal, frame):
def end():
"""Stop Glances."""
if core.is_standalone():
if core.is_standalone() and not WINDOWS:
# Stop the standalone (CLI)
standalone.end()
logger.info("Stop Glances (with CTRL-C)")
elif core.is_client():
elif core.is_client() and not WINDOWS:
# Stop the client
client.end()
logger.info("Stop Glances client (with CTRL-C)")
@ -82,7 +82,7 @@ def end():
# Stop the server
server.end()
logger.info("Stop Glances server (with CTRL-C)")
elif core.is_webserver():
elif core.is_webserver() or (core.is_standalone() and WINDOWS):
# Stop the Web server
webserver.end()
logger.info("Stop Glances web server(with CTRL-C)")