* ia64-tdep.c (ia64_convert_from_func_ptr_addr): Treat addresses
pointing inside a non-executable section as function descriptors.
This commit is contained in:
parent
02b19d8463
commit
b1e6fd1961
2 changed files with 11 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
|||
2008-05-06 Joel Brobecker <brobecker@adacore.com>
|
||||
|
||||
* ia64-tdep.c (ia64_convert_from_func_ptr_addr): Treat addresses
|
||||
pointing inside a non-executable section as function descriptors.
|
||||
|
||||
2008-05-06 Pedro Alves <pedro@codesourcery.com>
|
||||
|
||||
* inf-loop.c (inferior_event_handler): Run all continuations and
|
||||
|
|
|
@ -3229,6 +3229,12 @@ ia64_convert_from_func_ptr_addr (struct gdbarch *gdbarch, CORE_ADDR addr,
|
|||
if (s && strcmp (s->the_bfd_section->name, ".opd") == 0)
|
||||
return read_memory_unsigned_integer (addr, 8);
|
||||
|
||||
/* If ADDR points to a section that is not executable, then it cannot
|
||||
be pointing to a function. So it must be pointing to a function
|
||||
descriptor. */
|
||||
if (s && (s->the_bfd_section->flags & SEC_CODE) == 0)
|
||||
return read_memory_unsigned_integer (addr, 8);
|
||||
|
||||
/* There are also descriptors embedded in vtables. */
|
||||
if (s)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue