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

Unified Diff: android_webview/common/crash_reporter/aw_microdump_crash_reporter.cc

Issue 2694083004: Fix minidump-generation for debug builds. (Closed)
Patch Set: Remove unused fields from MinidumpInfo. Created 3 years, 10 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: android_webview/common/crash_reporter/aw_microdump_crash_reporter.cc
diff --git a/android_webview/common/crash_reporter/aw_microdump_crash_reporter.cc b/android_webview/common/crash_reporter/aw_microdump_crash_reporter.cc
index 3cf45d6bdcb69101d98746613194c90e6bc661b5..38633b5a0145f19a812bcc0c0e346a198263dfa4 100644
--- a/android_webview/common/crash_reporter/aw_microdump_crash_reporter.cc
+++ b/android_webview/common/crash_reporter/aw_microdump_crash_reporter.cc
@@ -156,20 +156,25 @@ void EnableCrashReporter(const std::string& process_type, int crash_signal_fd) {
client->set_crash_signal_fd(crash_signal_fd);
}
::crash_reporter::SetCrashReporterClient(client);
- breakpad::SetShouldSanitizeDumps(true);
-#if !defined(COMPONENT_BUILD)
- breakpad::SetSkipDumpIfPrincipalMappingNotReferenced(
- reinterpret_cast<uintptr_t>(&EnableCrashReporter));
-#endif
+ breakpad::SanitizationInfo sanitization_info;
+ sanitization_info.should_sanitize_dumps = true;
+#if defined(COMPONENT_BUILD)
+ sanitization_info.skip_dump_if_principal_mapping_not_referenced = false;
Primiano Tucci (use gerrit) 2017/02/15 18:39:07 there shouldn't be any need for this as false is t
gsennton 2017/02/16 10:46:49 Done.
+#else
+ sanitization_info.skip_dump_if_principal_mapping_not_referenced = true;
+ sanitization_info.address_within_principal_mapping =
+ reinterpret_cast<uintptr_t>(&EnableCrashReporter);
+#endif // defined(COMPONENT_BUILD)
bool is_browser_process =
process_type.empty() ||
process_type == breakpad::kWebViewSingleProcessType ||
process_type == breakpad::kBrowserProcessType;
if (is_browser_process) {
- breakpad::InitCrashReporter("");
+ breakpad::InitCrashReporter("", sanitization_info);
} else {
- breakpad::InitNonBrowserCrashReporterForAndroid(process_type);
+ breakpad::InitNonBrowserCrashReporterForAndroid(process_type,
+ sanitization_info);
}
g_enabled = true;
}

Powered by Google App Engine
This is Rietveld 408576698