LazDebuggerFp: Added safety measures for single stepping (Win64 SEH)

This commit is contained in:
Martin 2021-12-11 00:28:16 +01:00
parent 4c78791096
commit 97c29d9540

View File

@ -2750,6 +2750,8 @@ begin
// bplRtlRestoreContext
if assigned(FBreakPoints[bplRtlRestoreContext]) and FBreakPoints[bplRtlRestoreContext].HasLocation(PC) then begin
AFinishLoopAndSendEvents := False;
AnIsFinished := False;
if (CurrentCommand <> nil) and (CurrentCommand.Thread <> CurrentThread) then
exit;
debugln(FPDBG_COMMANDS, ['@ bplRtlRestoreContext ', DbgSName(CurrentCommand)]);
@ -2770,6 +2772,8 @@ begin
if assigned(FBreakPoints[bplRtlUnwind]) and FBreakPoints[bplRtlUnwind].HasLocation(PC) then begin
debugln(FPDBG_COMMANDS, ['@ bplRtlUnwind ', DbgSName(CurrentCommand)]);
AFinishLoopAndSendEvents := False;
AnIsFinished := False;
// This is Win64 bit only
// Must run for any thread => the thread may stop at a break in a finally block, and then attempt to step to except
// maybe store the thread-id with each breakpoint // though SP register values should be unique