Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(505)

Unified Diff: snapshot/mac/module_snapshot_mac.cc

Issue 997713002: Allow exception forwarding to the system’s native crash reporter to be disabled (Closed) Base URL: https://chromium.googlesource.com/crashpad/crashpad@master
Patch Set: Address review feedback Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: snapshot/mac/module_snapshot_mac.cc
diff --git a/snapshot/mac/module_snapshot_mac.cc b/snapshot/mac/module_snapshot_mac.cc
index ddbb6a00b9cb88fca15f6048b88f0b03d5317d43..0589bf7ad7f7d92ba827410524e0253a2aa2a522 100644
--- a/snapshot/mac/module_snapshot_mac.cc
+++ b/snapshot/mac/module_snapshot_mac.cc
@@ -55,6 +55,27 @@ bool ModuleSnapshotMac::Initialize(
return true;
}
+void ModuleSnapshotMac::GetCrashpadOptions(CrashpadInfoClientOptions* options) {
+ INITIALIZATION_STATE_DCHECK_VALID(initialized_);
+
+ process_types::CrashpadInfo crashpad_info;
+ if (!mach_o_image_reader_->GetCrashpadInfo(&crashpad_info)) {
+ options->crashpad_handler_behavior =
+ CrashpadInfoClientOptions::TriState::kDefault;
+ options->system_crash_reporter_forwarding =
+ CrashpadInfoClientOptions::TriState::kDefault;
+ return;
+ }
+
+ options->crashpad_handler_behavior =
+ CrashpadInfoClientOptions::TriStateFromCrashpadInfo(
+ crashpad_info.crashpad_handler_behavior);
+
+ options->system_crash_reporter_forwarding =
+ CrashpadInfoClientOptions::TriStateFromCrashpadInfo(
+ crashpad_info.system_crash_reporter_forwarding);
+}
+
std::string ModuleSnapshotMac::Name() const {
INITIALIZATION_STATE_DCHECK_VALID(initialized_);
return name_;

Powered by Google App Engine
This is Rietveld 408576698