aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog6
-rw-r--r--bfd/dwarf2.c2
2 files changed, 8 insertions, 0 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index a5e2304..9d23a8a 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,9 @@
+2021-01-23 H.J. Lu <hongjiu.lu@intel.com>
+
+ PR binutils/27231
+ * dwarf2.c (read_rnglists): Advance rngs_ptr after
+ _bfd_safe_read_leb128 when parsing DW_RLE_offset_pair.
+
2021-01-20 Alan Modra <amodra@gmail.com>
* elf32-ppc.c: Delete outdated comment.
diff --git a/bfd/dwarf2.c b/bfd/dwarf2.c
index d1770ae..292d60c 100644
--- a/bfd/dwarf2.c
+++ b/bfd/dwarf2.c
@@ -3265,9 +3265,11 @@ read_rnglists (struct comp_unit *unit, struct arange *arange,
low_pc = base_address;
low_pc += _bfd_safe_read_leb128 (abfd, rngs_ptr, &bytes_read,
FALSE, rngs_end);
+ rngs_ptr += bytes_read;
high_pc = base_address;
high_pc += _bfd_safe_read_leb128 (abfd, rngs_ptr, &bytes_read,
FALSE, rngs_end);
+ rngs_ptr += bytes_read;
break;
case DW_RLE_start_end: