Automatic crash dump generation from a DLL on Windows

887 Views Asked by At

My objective is to generate crash dumps whenever application crashes.

I have a DLL written with C++. It is used from a C# .NET application (among others). From within the DLL, I set my own custom unhandled exception filter with SetUnhandledExceptionFilter, and write a dump with MiniDumpWriteDump in the handler.

When I run the .NET application from within VS2008, it works fine, and when there is a memory access violation, the dump is written, and the application quits.

But when I run it outside VS as a standalone, my custom handler is not called at all and the dump is not written. Instead, an error dialog is shown with the message "Unhandled exception has occurred in your application..." and buttons "Details", "Continue" and "Quit".

I am guessing when I run it as standalone, the OS (Windows 7) is preventing my handler from being installed for some reason.

Can anyone help me with this?

0

There are 0 best solutions below