2

我从运行在 Windows XP SP3 上的本地服务应用程序的顶级异常处理程序调用MiniDumpWriteDump API,如下所示:

_MINIDUMP_EXCEPTION_INFORMATION ExInfo;
DWORD dwProcID = ::GetCurrentProcessId();
DWORD dwThreadID = ::GetCurrentThreadId();

ExInfo.ThreadId = dwThreadID;
ExInfo.ExceptionPointers = pExceptionInfo;   //Receive it from the exception handler
ExInfo.ClientPointers = NULL;

if(!pfnMiniDumpWriteDump(GetCurrentProcess(), dwProcID, hFile, MiniDumpNormal, &ExInfo, NULL, NULL))
{
    int nOSError = ::GetLastError();    //I receive 0x80070057
}

以上失败,错误代码为 0x80070057,但如果我将转储类型更改为 MiniDumpWithFullMemory,它就可以正常工作。知道为什么吗?

4

0 回答 0