Reputation: 5040
Suppose I've one visual c++ application which is having a main executable and many dlls. I have 2 configuration release and debug.
I just want to know what will be possible effect of using mix, I mean using using debug dll with release main exe or debug exe with release dlls.
Thanks
Upvotes: 3
Views: 3991
Reputation: 36318
I think the main potential problem would be that the DLLs won't be using the same runtime library as the executable.
That means that you can't share runtime objects such as file descriptors, and you can't allocate memory in one and release it in the other - although this won't be a problem if you follow best practice and always free memory from the same module it was allocated from.
There might also be an issue if you share non-POD (instances of a class, for example) between the DLLs and the executable. I'm not sure whether or not class instances are guaranteed to be binary compatible between debug and release.
Upvotes: 2