From b9d64784bb70afc211e8c95e108c75c03a23c5a0 Mon Sep 17 00:00:00 2001 From: Cheng Zhao Date: Sat, 26 Jul 2014 11:09:01 +0800 Subject: [PATCH] win: Don't crash on invalid parameter error. libuv relies on suppressing the invalid parameter error in uv__get_osfhandle, and it could hanppen frequently. Fixes #513. --- atom/common/crash_reporter/crash_reporter_win.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/atom/common/crash_reporter/crash_reporter_win.cc b/atom/common/crash_reporter/crash_reporter_win.cc index 6a581cc9710b..8131c482e822 100644 --- a/atom/common/crash_reporter/crash_reporter_win.cc +++ b/atom/common/crash_reporter/crash_reporter_win.cc @@ -54,12 +54,14 @@ void CrashReporterWin::InitBreakpad(const std::string& product_name, if (waiting_event != INVALID_HANDLE_VALUE) WaitForSingleObject(waiting_event, 1000); + int handler_types = google_breakpad::ExceptionHandler::HANDLER_EXCEPTION | + google_breakpad::ExceptionHandler::HANDLER_PURECALL; breakpad_.reset(new google_breakpad::ExceptionHandler( temp_dir.value(), FilterCallback, MinidumpCallback, this, - google_breakpad::ExceptionHandler::HANDLER_ALL, + handler_types, kSmallDumpType, pipe_name.c_str(), GetCustomInfo(product_name, version, company_name)));