Internet Direct (Indy) Version 9.0.2 Beta
TIdThreadMgrDefault.ReleaseThread
Frees a thread instance.

procedure ReleaseThread(AThread: TIdThread); override;
Parameters
AThread: TIdThread
Thread to be released.

Description
ReleaseThread is an implementation of the inherited abstract method that instructs the thread manager to terminate and free a thread instance.

If AThread is the current thread of execution, and has not been Suspended, the thread calls TerminateAndWaitFor to force termination of the active thread. TIdThread.Free is called to release the thread. If AThread is not the current thread, FreeOnTerminate is set to True.

ReleaseThread removes the thread from ActiveThreads prior to exiting from the method.