http://bugs.winehq.org/show_bug.cgi?id=28913
--- Comment #2 from aicommander@gmail.com 2011-10-28 00:32:55 CDT --- (In reply to comment #1)
Do you have an application that misbehaves because of this, or is this a pure speculation?
It causes a deadlock on ReactOS because the DLL loader unloads msafd.dll which frees a critical section that protects the socket list. In the closesocket() call, it tries to enter the critical section again to remove the socket, but the critical section is invalid so it deadlocks. This causes any apps that use wininet.dll to deadlock on close (until the lock is forcibly broken after the critical section timeout elapses). I'm trying to avoid simply hacking around the issue, so a real fix gets created for both WINE and ReactOS. If you've got any ideas, I'd be happy to give it a shot and upstream it to you guys if it works.