In the atlsmtpconnection.h file, the global variable declaration "__declspec(selectany) CSMTPWSAStartup _g_smtp_init;" calls "WSAStartup(ATLSMTP_WSA_VERSION, &wsadata)" in its constructor (see init() method).
This violates the rule that we may not call imported functions other than those located in Kernel32.dll (see "DllMain Restrictions" section at
Possible solutions (IMHO):
1) remove the init() call from the constructor of CSMTPWSAStartup
2) wrap the _g_smtp_init object in a songleton
Because of this issue, we had a crash when the DLLS were loaded (DllMain) -> hard to diagnose & debug. DLL Delay Load (in Visual Studio) helped, but it isn't a "real" solution...