mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-22 12:59:16 +02:00
FpDebug: Fix dangling pointer, if debug-backend sets breakpoint too late.
(cherry picked from commit ec98b15709
)
This commit is contained in:
parent
af2489f6ff
commit
fbb65eaa20
@ -2871,7 +2871,7 @@ end;
|
|||||||
|
|
||||||
procedure TDbgProcess.AfterBreakpointAdded(ABreak: TFpDbgBreakpoint);
|
procedure TDbgProcess.AfterBreakpointAdded(ABreak: TFpDbgBreakpoint);
|
||||||
begin
|
begin
|
||||||
if not assigned(FCurrentBreakpoint) then begin
|
if (FMainThread <> nil) and not assigned(FCurrentBreakpoint) then begin
|
||||||
if ABreak.HasLocation(FMainThread.GetInstructionPointerRegisterValue) then
|
if ABreak.HasLocation(FMainThread.GetInstructionPointerRegisterValue) then
|
||||||
FCurrentBreakpoint := TFpInternalBreakpoint(ABreak);
|
FCurrentBreakpoint := TFpInternalBreakpoint(ABreak);
|
||||||
end;
|
end;
|
||||||
|
Loading…
Reference in New Issue
Block a user