ProcessDebugger: Fixed crash, due to debugger destroying inside SetState

git-svn-id: trunk@61544 -
This commit is contained in:
martin 2019-07-08 19:11:16 +00:00
parent 787897eba2
commit c40bffbdee

View File

@ -91,8 +91,14 @@ end;
procedure TProcessDebugger.ProcessDestroyed(Sender: TObject);
begin
FProcess := nil;
if State <> dsIdle then
SetState(dsStop);
LockRelease;
try
if State <> dsIdle then
SetState(dsStop);
finally
UnlockRelease;
end;
end;
function TProcessDebugger.ProcessEnvironment(const AVariable: String; const ASet: Boolean): Boolean;