From: Tom Tromey Date: Mon, 1 Apr 2024 23:03:45 +0000 (-0600) Subject: Remove call to dwarf2_per_objfile::adjust from read_attribute_value X-Git-Tag: gdb-15-branchpoint~180 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=12fddc10c3ca745f98bd297ec72732adddb151c0;p=thirdparty%2Fbinutils-gdb.git Remove call to dwarf2_per_objfile::adjust from read_attribute_value Currently, read_attribute_value calls dwarf2_per_objfile::adjust on any address. This seems wrong, because the address may not even be in the text section. Luckily, this call is also not needed, because read_func_scope calls 'relocate', which does the same work. --- diff --git a/gdb/dwarf2/read.c b/gdb/dwarf2/read.c index 7caacd25474..68e093c2300 100644 --- a/gdb/dwarf2/read.c +++ b/gdb/dwarf2/read.c @@ -17010,7 +17010,6 @@ read_attribute_value (const struct die_reader_specs *reader, { unrelocated_addr addr = cu_header->read_address (abfd, info_ptr, &bytes_read); - addr = per_objfile->adjust (addr); attr->set_address (addr); info_ptr += bytes_read; }