all repos — mgba @ efa7f9701269b9e4d8a3acac4e5de4b2bbc6282b

mGBA Game Boy Advance Emulator

Perf: Fix race condition if a game crashes immediately on start
Jeffrey Pfau jeffrey@endrift.com
Sun, 10 May 2015 08:22:03 -0700
commit

efa7f9701269b9e4d8a3acac4e5de4b2bbc6282b

parent

a92d02c75616cd73de94226de62f7dae88e5c908

2 files changed, 8 insertions(+), 0 deletions(-)

jump to
M CHANGESCHANGES

@@ -35,6 +35,7 @@ - ARM7: Fix ARM multiply instructions when PC is a destination register

- SDL: Fix potential build issues when Qt and SDL2 are in use - GBA Memory: Fix jumping to invalid memory when switching from Thumb to ARM - GBA Video: Fix second frame mode 5 + - Perf: Fix race condition if a game crashes immediately on start Misc: - Qt: Show multiplayer numbers in window title - Qt: Solar sensor can have shortcuts set
M src/platform/perf-main.csrc/platform/perf-main.c

@@ -95,7 +95,14 @@

if (!didStart) { goto cleanup; } + GBAThreadInterrupt(&context); + if (GBAThreadHasCrashed(&context)) { + GBAThreadJoin(&context); + goto cleanup; + } + GBAGetGameCode(context.gba, gameCode); + GBAThreadContinue(&context); int frames = perfOpts.frames; if (!frames) {