FpDebug: Fixed IDE hang on linux. ExecuteInDebugThread can be called recursive (e.g., by MemReader)

git-svn-id: trunk@62491 -
This commit is contained in:
martin 2020-01-04 18:23:06 +00:00
parent 5301fa49cb
commit 6cc8e56bdc

View File

@ -2783,6 +2783,11 @@ end;
procedure TFpDebugDebugger.ExecuteInDebugThread(AMethod: TFpDbgAsyncMethod);
begin
if ThreadID = FFpDebugThread.ThreadID then begin
AMethod();
exit;
end;
assert(not assigned(FFpDebugThread.AsyncMethod));
FFpDebugThread.AsyncMethod:=AMethod;
RTLeventSetEvent(FFpDebugThread.StartDebugLoopEvent);