* Indy fix (freeonterminate workaround)

git-svn-id: trunk@2098 -
This commit is contained in:
marco 2005-12-31 15:40:19 +00:00
parent a5276e396e
commit 2dbe7d22c2

View File

@ -205,7 +205,7 @@ end;
destructor TThread.Destroy;
begin
if (FThreadID = GetCurrentThreadID) and not(FFreeOnTerminate) then begin
if (FThreadID = GetCurrentThreadID) and not(FFreeOnTerminate) and not ffinished then begin
raise EThreadDestroyCalled.Create('A thread cannot destroy itself except by setting FreeOnTerminate and leaving!');
end;
// if someone calls .Free on a thread with