From: Jim Wilson Date: Mon, 14 Nov 2005 22:23:32 +0000 (+0000) Subject: Fix gcc bug 24490, location list query failed due to out-of-range address. X-Git-Tag: gdb_6_4-20051202-release~31 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6066b77ff77fe5f7930898e71909eb9a4d69f072;p=thirdparty%2Fbinutils-gdb.git Fix gcc bug 24490, location list query failed due to out-of-range address. PR 2024 * dwarf2loc.c (dwarf_expr_frame_base): Use get_frame_address_in_block instead of get_frame_pc. (loclist_read_variable): Likewise. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 1f5fd4e2f6b..7fe4cdb44df 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,10 @@ +2005-11-14 James E Wilson + + PR 2024 + * dwarf2loc.c (dwarf_expr_frame_base): Use get_frame_address_in_block + instead of get_frame_pc. + (loclist_read_variable): Likewise. + 2005-11-14 Paul Gilliam * ppc-sysv-tdep.c (ppc64_sysv_abi_return_value): Copy code from diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c index fea2c99a9d5..8a3e99faf31 100644 --- a/gdb/dwarf2loc.c +++ b/gdb/dwarf2loc.c @@ -164,9 +164,11 @@ dwarf_expr_frame_base (void *baton, gdb_byte **start, size_t * length) if (SYMBOL_OPS (framefunc) == &dwarf2_loclist_funcs) { struct dwarf2_loclist_baton *symbaton; + struct frame_info *frame = debaton->frame; + symbaton = SYMBOL_LOCATION_BATON (framefunc); *start = find_location_expression (symbaton, length, - get_frame_pc (debaton->frame)); + get_frame_address_in_block (frame)); } else { @@ -597,7 +599,8 @@ loclist_read_variable (struct symbol *symbol, struct frame_info *frame) size_t size; data = find_location_expression (dlbaton, &size, - frame ? get_frame_pc (frame) : 0); + frame ? get_frame_address_in_block (frame) + : 0); if (data == NULL) { val = allocate_value (SYMBOL_TYPE (symbol));