This project has moved. For the latest updates, please go here.

Interesting case of mixed MSVC runtime DLLs causing a crash.

Sep 1, 2010 at 7:54 PM

Hi,

I have a unique configuration that is generating a crash with VLD 2.0b:

My main project executable is a native Win32 application built in Visual Studio 2010 (MSVCR100). During initialization this executable calls LoadLibrary() on a .NET 2.0 C++/CLR DLL that serves as a bridge to another .NET 2.0 C# assembly. The unusual bit is that since VS2010 does NOT support .NET 2.0 CLR natively (argh), the C++/CLR bridge DLL is still being built using Visual Studio 2008 (MSVCR90).

It seems that VLD links the MSVCR100 environment since vld.h is included in the main executable. This makes sense, but it leads to a crash as soon as the VS2008 built code tries to allocate memory.

Is there any way to tell VLD not to link to this module? As far as I can tell VLDDisableModule() will not help because this is a link-time issue.

 

Thank you.