Help mu for Thread stop


2006-11-05 07:03:48 PM
cppbuilder41
In Thread I have insert accept(socket....
Button Listen:
MyVarTh1 = new MyClass (true);
MyVarTh1->MyListen();
MyVarTh1->Resume(); --->here accept(socket...)
Button Block:
MyVarTh1->Suspend();
MyVarTh1->Terminate();
MyVarTh1->MyCloseSock();
MyVarTh1->~MyClass();
My questions is:
is it correctly the order of Suspend-->Terminate-->CloseSock-->Destructor?
What's the good way? I must destructor myclass or only Terminated my
thread? Thanks