The information in this article applies to:
SYMPTOMSWhen you call MFC socket functions from ExitInstance of a DLL, the functions may fail and return an error. CAUSE
In an MFC DLL, the CWinApp::ExitInstance function is called from the
DllMain function in response to the DLL_PROCESS_DETACH case. RESOLUTIONDo not call socket functions from CWinApp::ExitInstance (DLL_PROCESS_DETACH). Provide a cleanup function that the application can call to perform the last socket functions. STATUSThis behavior is by design. MORE INFORMATION
A common mistake is to call the CSocket::Close (or CAsyncSocket::Close)
function in CWinApp::ExitInstance. This can generate an assertion in
sockcore.cpp line 856 in Microsoft Visual C++ 5.0, and line 667 in
Microsoft Visual C++ 6.0. Additional query words:
Keywords : kbDLL kbMFC kbVC400 kbVC410 kbVC420 kbVC500 kbVC600 kbWinsock |
Last Reviewed: July 26, 1999 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |