diff --git a/handler/linux/crash_report_exception_handler.cc b/handler/linux/crash_report_exception_handler.cc index 345e234d..e65b26e8 100644 --- a/handler/linux/crash_report_exception_handler.cc +++ b/handler/linux/crash_report_exception_handler.cc @@ -140,7 +140,7 @@ bool CrashReportExceptionHandler::HandleExceptionWithConnection( ProcessSnapshot* snapshot = nullptr; ProcessSnapshotSanitized sanitized; - std::vector whitelist; + std::vector annotations_whitelist; if (info.sanitization_information_address) { SanitizationInformation sanitization_info; ProcessMemoryRange range; @@ -157,7 +157,7 @@ bool CrashReportExceptionHandler::HandleExceptionWithConnection( !ReadAnnotationsWhitelist( range, sanitization_info.annotations_whitelist_address, - &whitelist)) { + &annotations_whitelist)) { Metrics::ExceptionCaptureResult( Metrics::CaptureResult::kSanitizationInitializationFailed); return false; @@ -165,7 +165,7 @@ bool CrashReportExceptionHandler::HandleExceptionWithConnection( if (!sanitized.Initialize(&process_snapshot, sanitization_info.annotations_whitelist_address - ? &whitelist + ? &annotations_whitelist : nullptr, sanitization_info.target_module_address, sanitization_info.sanitize_stacks)) { diff --git a/snapshot/sanitized/process_snapshot_sanitized_test.cc b/snapshot/sanitized/process_snapshot_sanitized_test.cc index f4c852f9..e01ff324 100644 --- a/snapshot/sanitized/process_snapshot_sanitized_test.cc +++ b/snapshot/sanitized/process_snapshot_sanitized_test.cc @@ -252,12 +252,12 @@ class SanitizeTest : public MultiprocessExec { ExpectAnnotations(&snapshot, /* sanitized= */ false); ExpectStackData(&snapshot, addrs, /* sanitized= */ false); - std::vector whitelist; - whitelist.push_back(kWhitelistedAnnotationName); + std::vector annotations_whitelist; + annotations_whitelist.push_back(kWhitelistedAnnotationName); ProcessSnapshotSanitized sanitized; ASSERT_TRUE(sanitized.Initialize( - &snapshot, &whitelist, addrs.module_address, true)); + &snapshot, &annotations_whitelist, addrs.module_address, true)); ExpectAnnotations(&sanitized, /* sanitized= */ true); ExpectStackData(&sanitized, addrs, /* sanitized= */ true); diff --git a/snapshot/sanitized/sanitization_information.cc b/snapshot/sanitized/sanitization_information.cc index f7be9b08..d97f706f 100644 --- a/snapshot/sanitized/sanitization_information.cc +++ b/snapshot/sanitized/sanitization_information.cc @@ -21,9 +21,9 @@ namespace crashpad { namespace { template -bool ReadWhitelist(const ProcessMemoryRange& memory, - VMAddress whitelist_address, - std::vector* whitelist) { +bool ReadAnnotationsWhitelist(const ProcessMemoryRange& memory, + VMAddress whitelist_address, + std::vector* whitelist) { if (!whitelist_address) { return true; } @@ -53,9 +53,10 @@ bool ReadWhitelist(const ProcessMemoryRange& memory, bool ReadAnnotationsWhitelist(const ProcessMemoryRange& memory, VMAddress whitelist_address, std::vector* whitelist) { - return memory.Is64Bit() - ? ReadWhitelist(memory, whitelist_address, whitelist) - : ReadWhitelist(memory, whitelist_address, whitelist); + return memory.Is64Bit() ? ReadAnnotationsWhitelist( + memory, whitelist_address, whitelist) + : ReadAnnotationsWhitelist( + memory, whitelist_address, whitelist); } } // namespace crashpad