win_glue DLLMain problems with WSAStartup / WSACleanup

Jeffrey Altman jaltman at
Fri Mar 25 09:56:07 EST 2005

Ken Raeburn wrote:
> On Mar 25, 2005, at 05:14, Jeffrey Altman wrote:
>> In the DllMain() function of our DLLs, we currently call WSAStartup at 
>> process attach and WSACleanup at process detach.  When the Microsoft
>> Internet Connection Firewall is enabled, the call to WSACleanup will
>> produce a deadlock.
> Ick.  Is this specific to the Load/FreeLibrary or process 
> startup/termination case, or does it apply to both cases?

It is a problem with both cases.  However, it is the FreeLibrary case
which is most likely to result in deadlock.  krb5-bugs is about to
receive a bug report indicating that the use of krb5_32.dll in a
Network Provider Logon DLL results in a deadlock when FreeLibrary is

- Jeff

More information about the krbdev mailing list