Fix shutdown because of Discord deinitializer

https://github.com/hrydgard/ppsspp/blob/f94beb518504eebadb94dfdc009cf9f4461bc6a4/UI/DiscordIntegration.cpp#L40
Calling exit(0) without NativeShutdown() breaks the assertion.
This commit is contained in:
Xie Yi committed 2019-06-11 14:44:06 +08:00
1 parent 364b447ee4
commit 1affe0bff3
2 files changed
+6 -2

No files matched your search

+2 -1
View File
@@ -213,7 +213,6 @@ static GraphicsContext *graphicsContext;
time_update();
}
threadStopped = true;
ILOG("Emulation thread shutting down\n");
NativeShutdownGraphics();
@@ -221,6 +220,8 @@ static GraphicsContext *graphicsContext;
// Also ask the main thread to stop, so it doesn't hang waiting for a new frame.
ILOG("Emulation thread stopping\n");
graphicsContext->StopThread();
threadStopped = true;
});
}
+4 -1
View File
@@ -61,7 +61,10 @@ bool System_GetPropertyBool(SystemProperty prop) {
void System_SendMessage(const char *command, const char *parameter) {
if (!strcmp(command, "finish")) {
exit(0);
dispatch_async(dispatch_get_main_queue(), ^{
[sharedViewController shutdown];
exit(0);
});
}
}