From 6782735d48b8b61e844861020f96e9c71cc45258 Mon Sep 17 00:00:00 2001 From: Cary Coutant Date: Mon, 9 Apr 2012 23:32:20 +0000 Subject: [PATCH] * gdb-index.cc (Gdb_index_info_reader::record_cu_ranges): Allow low_pc == 0. --- gold/ChangeLog | 5 +++++ gold/gdb-index.cc | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/gold/ChangeLog b/gold/ChangeLog index c663ca7b19b..d6b02a69327 100644 --- a/gold/ChangeLog +++ b/gold/ChangeLog @@ -1,3 +1,8 @@ +2012-04-09 Cary Coutant + + * gdb-index.cc (Gdb_index_info_reader::record_cu_ranges): Allow + low_pc == 0. + 2012-04-06 Ian Lance Taylor * timer.cc: #include . diff --git a/gold/gdb-index.cc b/gold/gdb-index.cc index 11b732a21c8..16e387180fd 100644 --- a/gold/gdb-index.cc +++ b/gold/gdb-index.cc @@ -825,7 +825,7 @@ Gdb_index_info_reader::record_cu_ranges(Dwarf_die* die) off_t low_pc = die->ref_attribute(elfcpp::DW_AT_low_pc, &shndx); off_t high_pc = die->ref_attribute(elfcpp::DW_AT_high_pc, &shndx2); - if (low_pc != 0 && high_pc != 0 && low_pc != -1 && high_pc != -1) + if ((low_pc != 0 || high_pc != 0) && low_pc != -1 && high_pc != -1) { if (shndx != shndx2) { -- 2.39.2