aboutsummaryrefslogtreecommitdiff
path: root/src/common/dwarf_cu_to_module.cc
diff options
context:
space:
mode:
authorSterling Augustine <saugustine@google.com>2020-07-24 14:11:05 -0700
committerSterling Augustine <saugustine@google.com>2020-07-24 21:34:14 +0000
commit7d65240249584aed1c123e286c8468a7d824e9d0 (patch)
treeea8c13528d67845901413fc59b8459dca9914afd /src/common/dwarf_cu_to_module.cc
parentPort new symbol API to symupload on Mac. (diff)
downloadbreakpad-7d65240249584aed1c123e286c8468a7d824e9d0.tar.xz
Properly handle new tombstone values that now appear as a result of the llvm change described at https://reviews.llvm.org/D81784.
Change-Id: I79dc5a72b651aa057104cd42b4773391df68125b Reviewed-on: https://chromium-review.googlesource.com/c/breakpad/breakpad/+/2317730 Reviewed-by: Mark Mentovai <mark@chromium.org> Reviewed-by: Nelson Billing <nbilling@google.com>
Diffstat (limited to 'src/common/dwarf_cu_to_module.cc')
-rw-r--r--src/common/dwarf_cu_to_module.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/common/dwarf_cu_to_module.cc b/src/common/dwarf_cu_to_module.cc
index 3a520857..c4eb3c50 100644
--- a/src/common/dwarf_cu_to_module.cc
+++ b/src/common/dwarf_cu_to_module.cc
@@ -1195,7 +1195,10 @@ void DwarfCUToModule::AssignLinesToFunctions() {
// next_transition may end up being zero, in which case we've completed
// our pass. Handle that here, instead of trying to deal with it in
// each place we compute next_transition.
- if (!next_transition)
+
+ // Some dwarf producers handle linker-removed functions by using -1 as a
+ // tombstone in the line table. So the end marker can be -1.
+ if (!next_transition || next_transition == Module::kMaxAddress)
break;
// Advance iterators as needed. If lines overlap or functions overlap,