calmdump是用于Windows C++服务端的crash report组件,从crashrpt里面提取出核心的异常处理代码,并增加了异常堆栈打印。
calmdump takes the core exception handling code in crashrpt, but no client-only feature(screen capturing, file compression, video recording etc). on collect the minidump file and print stack information to a specified file.
#include <Windows.h>
#include <CrashRpt.h>
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE, LPSTR lpCmdLine, int nCmdShow)
{
crInstall(); // this API handles everything
// do your own job
}
- Obtain CMake
mkdir build && cd build && cmake ..
A Crash Course on the Depths of Win32™ Structured Exception Handling