From 4673c67835d478e343e58f0160f240b7d3b8c828 Mon Sep 17 00:00:00 2001 From: Ales Pergl Date: Fri, 9 Mar 2018 15:44:37 +0100 Subject: [PATCH] Fixed passing of exception to the system crash handler --- atom/common/crash_reporter/crash_reporter_win.cc | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/atom/common/crash_reporter/crash_reporter_win.cc b/atom/common/crash_reporter/crash_reporter_win.cc index a7908ef30c6b..49f90b7e6665 100644 --- a/atom/common/crash_reporter/crash_reporter_win.cc +++ b/atom/common/crash_reporter/crash_reporter_win.cc @@ -209,7 +209,10 @@ void CrashReporterWin::SetUploadParameters() { int CrashReporterWin::CrashForException(EXCEPTION_POINTERS* info) { if (breakpad_) { breakpad_->WriteMinidumpForException(info); - TerminateProcessWithoutDump(); + if (skip_system_crash_handler_) + TerminateProcessWithoutDump(); + else + RaiseFailFastException(info->ExceptionRecord, info->ContextRecord, 0); } return EXCEPTION_CONTINUE_SEARCH; } @@ -229,7 +232,7 @@ bool CrashReporterWin::MinidumpCallback(const wchar_t* dump_path, MDRawAssertionInfo* assertion, bool succeeded) { CrashReporterWin* self = static_cast(context); - if (succeeded && !self->skip_system_crash_handler_) + if (succeeded && self->skip_system_crash_handler_) return true; else return false;