Kyle
Kyle

Reputation: 17677

Debugging MMC (Unmanaged c++)?

I work on a legacy MMC application and one thing I have noticed is that once in awhile when closing the MMC, an error will be reported.

"MMC has detected an error in a snap-in. It is recommended that you shut down and restart MMC".

How can I debug this? The error is not displayd until you close the console and if you try to attach a debugger, it just exits instantly.

Any thoughts?

Upvotes: 1

Views: 1206

Answers (1)

Shay Erlichmen
Shay Erlichmen

Reputation: 31928

Why not run the MMC under debugger? Clearly there is something wrong (Unhandled exception probably) with the shutdown code of the snapin.

Just run mmc.exe under your favorite debugger and tell the debugger to stop on all exception. attach your snapin exit and wait for the crash.


You can try to run ProcDump which can create dump files on Unhandled exception.

Upvotes: 3

Related Questions