diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2017-01-02 19:26:05 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2017-01-02 19:26:05 +0000 |
commit | 14f1b3e8826ce43b978db93a62d1166055db5394 (patch) | |
tree | 0a00ad8d3498783fe0193f3b656bca17c4c8697d /packages/Python/lldbsuite/test/functionalities/postmortem/minidump-new/install_breakpad.cpp | |
parent | 4ee8c119c71a06dcad1e0fecc8c675e480e59337 (diff) |
Notes
Diffstat (limited to 'packages/Python/lldbsuite/test/functionalities/postmortem/minidump-new/install_breakpad.cpp')
-rw-r--r-- | packages/Python/lldbsuite/test/functionalities/postmortem/minidump-new/install_breakpad.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/packages/Python/lldbsuite/test/functionalities/postmortem/minidump-new/install_breakpad.cpp b/packages/Python/lldbsuite/test/functionalities/postmortem/minidump-new/install_breakpad.cpp new file mode 100644 index 000000000000..c34ac17128fa --- /dev/null +++ b/packages/Python/lldbsuite/test/functionalities/postmortem/minidump-new/install_breakpad.cpp @@ -0,0 +1,16 @@ +#include "client/linux/handler/exception_handler.h" + +static bool dumpCallback(const google_breakpad::MinidumpDescriptor &descriptor, + void *context, bool succeeded) { + return succeeded; +} + +google_breakpad::ExceptionHandler *eh; + +void InstallBreakpad() { + google_breakpad::MinidumpDescriptor descriptor("/tmp"); + eh = new google_breakpad::ExceptionHandler(descriptor, NULL, dumpCallback, + NULL, true, -1); +} + +void WriteMinidump() { eh->WriteMinidump(); } |