aboutsummaryrefslogtreecommitdiff
path: root/binutils
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2024-06-17 15:51:13 +0930
committerAlan Modra <amodra@gmail.com>2024-06-17 15:57:50 +0930
commit1b19566b18a1208f84b89029785a1e93a6544514 (patch)
tree0d5119e792dd9c32fa47af7d0b2e3461bac88142 /binutils
parent2df6e967098a2f48a83a2ec6000a9c53b493c737 (diff)
downloadgdb-1b19566b18a1208f84b89029785a1e93a6544514.zip
gdb-1b19566b18a1208f84b89029785a1e93a6544514.tar.gz
gdb-1b19566b18a1208f84b89029785a1e93a6544514.tar.bz2
PR31898 bug in processing DW_RLE_startx_endx
PR 31898 * dwarf.c (display_debug_rnglists_list): Correct fetch of "end" indexed address. Remove excess parens.
Diffstat (limited to 'binutils')
-rw-r--r--binutils/dwarf.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/binutils/dwarf.c b/binutils/dwarf.c
index d375148..d1699e7 100644
--- a/binutils/dwarf.c
+++ b/binutils/dwarf.c
@@ -8145,7 +8145,7 @@ display_debug_rnglists_list (unsigned char * start,
READ_ULEB (base_address, start, finish);
print_hex (base_address, pointer_size);
printf (_("(base address index) "));
- base_address = fetch_indexed_addr ((base_address * pointer_size) + addr_base,
+ base_address = fetch_indexed_addr (base_address * pointer_size + addr_base,
pointer_size);
print_hex (base_address, pointer_size);
printf (_("(base address)\n"));
@@ -8153,15 +8153,15 @@ display_debug_rnglists_list (unsigned char * start,
case DW_RLE_startx_endx:
READ_ULEB (begin, start, finish);
READ_ULEB (end, start, finish);
- begin = fetch_indexed_addr ((begin * pointer_size) + addr_base,
+ begin = fetch_indexed_addr (begin * pointer_size + addr_base,
pointer_size);
- end = fetch_indexed_addr ((begin * pointer_size) + addr_base,
+ end = fetch_indexed_addr (end * pointer_size + addr_base,
pointer_size);
break;
case DW_RLE_startx_length:
READ_ULEB (begin, start, finish);
READ_ULEB (length, start, finish);
- begin = fetch_indexed_addr ((begin * pointer_size) + addr_base,
+ begin = fetch_indexed_addr (begin * pointer_size + addr_base,
pointer_size);
end = begin + length;
break;