From 33414779e1c16704897a06ecb335aa9f9a2b46d7 Mon Sep 17 00:00:00 2001 From: Hans Wennborg Date: Wed, 25 Nov 2015 23:50:31 -0500 Subject: [PATCH] Build fixes for Clang on Windows See e.g. http://build.chromium.org/p/chromium.fyi/builders/CrWinClang/builds/4502/steps/compile/logs/stdio BUG=chromium:82385 R=mark@chromium.org Review URL: https://codereview.chromium.org/1473073008 . Patch from Hans Wennborg . --- snapshot/win/pe_image_reader.cc | 4 +++- snapshot/win/process_snapshot_win.cc | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/snapshot/win/pe_image_reader.cc b/snapshot/win/pe_image_reader.cc index 82bce064..f408fb18 100644 --- a/snapshot/win/pe_image_reader.cc +++ b/snapshot/win/pe_image_reader.cc @@ -86,8 +86,10 @@ bool PEImageReader::GetCrashpadInfo( INITIALIZATION_STATE_DCHECK_VALID(initialized_); IMAGE_SECTION_HEADER section; - if (!GetSectionByName::type>("CPADinfo", §ion)) + if (!GetSectionByName::type>("CPADinfo", + §ion)) { return false; + } if (section.Misc.VirtualSize < sizeof(process_types::CrashpadInfo)) { LOG(WARNING) << "small crashpad info section size " diff --git a/snapshot/win/process_snapshot_win.cc b/snapshot/win/process_snapshot_win.cc index 4146ae8d..b8498d6c 100644 --- a/snapshot/win/process_snapshot_win.cc +++ b/snapshot/win/process_snapshot_win.cc @@ -380,9 +380,9 @@ void ProcessSnapshotWin::AddMemorySnapshotForLdrLIST_ENTRY( PointerVector* into) { // Walk the doubly-linked list of entries, adding the list memory itself, as // well as pointed-to strings. - Traits::Pointer last = le.Blink; + typename Traits::Pointer last = le.Blink; process_types::LDR_DATA_TABLE_ENTRY entry; - Traits::Pointer cur = le.Flink; + typename Traits::Pointer cur = le.Flink; for (;;) { // |cur| is the pointer to LIST_ENTRY embedded in the LDR_DATA_TABLE_ENTRY. // So we need to offset back to the beginning of the structure.