mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-07-18 03:09:18 +02:00
Fix crash on exit
This commit is contained in:
@@ -615,8 +615,19 @@ eu07_application::release_python_lock() {
|
||||
void
|
||||
eu07_application::exit() {
|
||||
Global.applicationQuitOrder = true;
|
||||
Global.threads["LogService"].join(); // kill log service
|
||||
Global.threads["DiscordRPC"].join(); // kill DiscordRPC service
|
||||
auto it = Global.threads.find("LogService");
|
||||
if (it != Global.threads.end())
|
||||
{
|
||||
if (it->second.joinable())
|
||||
it->second.join();
|
||||
}
|
||||
|
||||
it = Global.threads.find("DiscordRPC");
|
||||
if (it != Global.threads.end())
|
||||
{
|
||||
if (it->second.joinable())
|
||||
it->second.join();
|
||||
}
|
||||
|
||||
|
||||
for (auto &mode : m_modes)
|
||||
|
||||
Reference in New Issue
Block a user