Crashes in ATL conversion macros
-
We have been encountering crashes in ATL conversion macros where the ATL library function pointer g_pfnGetThreadACP points not to an actual function but into thin air. The call through g_pfnGetThreadACP can be eliminated by compiling with _CONVERSION_DONT_USE_THREAD_LOCALE defined, but this loses the thread-specific code page in our multithreaded programs. There is no compiler option to simply use CP_THREAD_ACP, although the restriction to Windows 2000 and later would be more than enough for our needs. The programs that have been crashing are compiled with Visual Studio 2005 in release build; debugging builds and similar programs compiled with Visual Studio 2003 do not crash. All programs that have crashed use an in-house port of Objective Grid 9.02 to VS8 which we have used for over a year but programs only just started crashing so there must have been something else that has changed. All crashes have either been when the program has been initializing (MFC InitInstance()) or closing down. Has anyone got any ideas?
-
We have been encountering crashes in ATL conversion macros where the ATL library function pointer g_pfnGetThreadACP points not to an actual function but into thin air. The call through g_pfnGetThreadACP can be eliminated by compiling with _CONVERSION_DONT_USE_THREAD_LOCALE defined, but this loses the thread-specific code page in our multithreaded programs. There is no compiler option to simply use CP_THREAD_ACP, although the restriction to Windows 2000 and later would be more than enough for our needs. The programs that have been crashing are compiled with Visual Studio 2005 in release build; debugging builds and similar programs compiled with Visual Studio 2003 do not crash. All programs that have crashed use an in-house port of Objective Grid 9.02 to VS8 which we have used for over a year but programs only just started crashing so there must have been something else that has changed. All crashes have either been when the program has been initializing (MFC InitInstance()) or closing down. Has anyone got any ideas?
1. Trace into the code and find why g_pfnGetThreadACP isn't being set. 2. Set a data breakpoint on g_pfnGetThreadACP and find what's zeroing it out.
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p