diff --git a/src/system_tray.cpp b/src/system_tray.cpp index cab3ee9b72f..95eb9a7e41f 100644 --- a/src/system_tray.cpp +++ b/src/system_tray.cpp @@ -115,11 +115,12 @@ namespace system_tray { // If we're running in a service, return a special status to // tell it to terminate too, otherwise it will just respawn us. if (GetConsoleWindow() == NULL) { - lifetime::exit_sunshine(ERROR_SHUTDOWN_IN_PROGRESS, false); + lifetime::exit_sunshine(ERROR_SHUTDOWN_IN_PROGRESS, true); + return; } #endif - lifetime::exit_sunshine(0, false); + lifetime::exit_sunshine(0, true); } // Tray menu