Debugger: Close trace log when done tracing

This commit is contained in:
Vicki Pfau 2020-11-09 00:08:36 -08:00
parent 82f3432e7a
commit f70185da5f
2 changed files with 7 additions and 1 deletions

View File

@ -3,6 +3,7 @@ Emulation fixes:
- ARM: Fix Addressing mode 1 shifter on rs == pc (fixes mgba.io/i/1926)
Other fixes:
- CMake: Fix build with downstream minizip that exports incompatible symbols
- Debugger: Close trace log when done tracing
0.8.4: (2020-10-29)
Emulation fixes:

View File

@ -723,7 +723,12 @@ static bool _doTrace(struct CLIDebugger* debugger) {
if (debugger->traceRemaining > 0) {
--debugger->traceRemaining;
}
return debugger->traceRemaining != 0;
if (!debugger->traceRemaining) {
debugger->traceVf->close(debugger->traceVf);
debugger->traceVf = NULL;
return false;
}
return true;
}
static void _printStatus(struct CLIDebugger* debugger, struct CLIDebugVector* dv) {