Re: WSACleanup deadlock

Tech-Archive recommends: Fix windows errors by optimizing your registry



Mila wrote:
Before WSACleanup is called I close open sockets then terminate
threads if active so there doesn't exist any open sockets or thread
handles.

Are you sure? Do you wait on all thread handles? If not you should.
Also how do you terminate threads? If you call TerminateThread this is not a
good idea (though it is unlikely to cause your particular problem). Make
sure your threads exit cleanly by themselves.

--
Eugene
http://www.gershnik.com


.