Fall back to single stepping if address range from GDB is less than one word.

This commit is contained in:
Nav
2023-09-16 03:06:18 +01:00
parent ea33faf535
commit be5e89456c

View File

@@ -88,7 +88,7 @@ namespace DebugServer::Gdb::AvrGdb::CommandPackets
debugSession.terminateRangeSteppingSession(targetControllerService);
}
if (this->startAddress == this->endAddress || (this->endAddress - this->startAddress) == 2) {
if (this->startAddress == this->endAddress || (this->endAddress - this->startAddress) <= 2) {
// Single step requested. No need for a range step here.
targetControllerService.stepTargetExecution(std::nullopt);
debugSession.waitingForBreak = true;