Fix #20356 - Flatpak application doesn't close until controller is unplugged.

When the controller is connected SLD sends a lot of events (`SDL_JOYAXISMOTION` and etc.),
so PPSSPP is stuck in the loop to process these events. Fixed by duplicating the `if` statement
to check whether the quit was requested inside the loop.
This commit is contained in:
Dmytro Kyshchenko committed 2026-01-28 16:40:01 +02:00
1 parent b5109db434
commit 73e0bb651e
1 file changed
+4
+4
View File
@@ -1797,8 +1797,12 @@ int main(int argc, char *argv[]) {
while (true) {
SDL_Event event;
while (SDL_WaitEventTimeout(&event, 100)) {
if (g_QuitRequested || g_RestartRequested)
break;
ProcessSDLEvent(window, event, &inputTracker);
}
if (g_QuitRequested || g_RestartRequested)
break;