From b3c763a5f30ab8743a5c33339bb93b79ec6738eb Mon Sep 17 00:00:00 2001 From: Sour Date: Sat, 16 Jun 2018 17:09:37 -0400 Subject: [PATCH] Debugger: Fixed issue with "set next statement" and assembler's "execute" feature --- Core/Debugger.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Core/Debugger.cpp b/Core/Debugger.cpp index 612b4e9c..bde6c6d7 100644 --- a/Core/Debugger.cpp +++ b/Core/Debugger.cpp @@ -963,11 +963,14 @@ void Debugger::SetNextStatement(uint16_t addr) if(_currentReadAddr) { _cpu->SetDebugPC(addr); *_currentReadAddr = addr; - *_currentReadValue = _memoryManager->DebugRead(addr, true); + *_currentReadValue = _memoryManager->DebugRead(addr, false); } else { //Can't change the address right away (CPU is in the middle of an instruction) //Address will change after current instruction is done executing _nextReadAddr = addr; + + //Force the current instruction to finish + Step(1); } }