Explorar el Código

* Indy fix (freeonterminate workaround)

git-svn-id: trunk@2098 -
marco hace 19 años
padre
commit
2dbe7d22c2
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      rtl/freebsd/tthread.inc

+ 1 - 1
rtl/freebsd/tthread.inc

@@ -205,7 +205,7 @@ end;
 
 
 destructor TThread.Destroy;
 destructor TThread.Destroy;
 begin
 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!');
     raise EThreadDestroyCalled.Create('A thread cannot destroy itself except by setting FreeOnTerminate and leaving!');
   end;
   end;
   // if someone calls .Free on a thread with
   // if someone calls .Free on a thread with