Hello.
I have a very strange problem related to debugging of self-coded DLLs. I have an MFC-driven dialog-based application, several projects linked statically and several DLL-projects which are loaded at runtime.
I build solution in debug, run the application and I can easily debug those DLL-projects. Now the problem. If there is some obvious runtime error in DLL like following
int* i = 0;
*i = 4;
debugger asserts no error, throws no exception and silently returns to idle state with even no (visible) stack returns. It looks like when I'm hitting F10 on the statement *i = 4;
, the control returns to main application window and program execution continues as nothing happened! And if there are no errors in the code, it executes fine. But I expect errors to be asserted in this case! And they are - in the main application's code.
I use LoadLibrary() function to load my DLL into application. DLL itself has MFC statically linked, same as every other project in solution has.
Any ideas? Don't even know what question to google...