mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-11-23 09:39:37 +01:00
FpDebug: Ensure that exit thread aborts any running command. (The command may change the event-enum-code in FPDEvent, and try to continue running)
git-svn-id: trunk@61864 -
This commit is contained in:
parent
479abc2507
commit
df6722dd5f
@ -767,6 +767,11 @@ var
|
|||||||
|
|
||||||
begin
|
begin
|
||||||
AExit:=false;
|
AExit:=false;
|
||||||
|
if FCurrentProcess = nil then begin
|
||||||
|
DebugLn(DBG_WARNINGS, 'Error: Processloop has no process');
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
|
||||||
repeat
|
repeat
|
||||||
if assigned(FCurrentProcess) and not assigned(FMainProcess) then
|
if assigned(FCurrentProcess) and not assigned(FMainProcess) then
|
||||||
FMainProcess:=FCurrentProcess
|
FMainProcess:=FCurrentProcess
|
||||||
@ -849,6 +854,9 @@ begin
|
|||||||
FCurrentProcess.FormatAddress(FCurrentThread.GetStackPointerRegisterValue),
|
FCurrentProcess.FormatAddress(FCurrentThread.GetStackPointerRegisterValue),
|
||||||
FCurrentProcess.FormatAddress(FCurrentThread.GetStackBasePointerRegisterValue),
|
FCurrentProcess.FormatAddress(FCurrentThread.GetStackBasePointerRegisterValue),
|
||||||
dbgs(CurrentProcess.CurrentBreakpoint<>nil)]);
|
dbgs(CurrentProcess.CurrentBreakpoint<>nil)]);
|
||||||
|
if FPDEvent=deExitProcess then
|
||||||
|
FreeAndNil(FCommand)
|
||||||
|
else
|
||||||
if assigned(FCommand) then
|
if assigned(FCommand) then
|
||||||
begin
|
begin
|
||||||
FCommand.ResolveEvent(FPDEvent, IsHandled, IsFinished);
|
FCommand.ResolveEvent(FPDEvent, IsHandled, IsFinished);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user