[PATCH] Use read_memory_unsigned_integer when reading to CORE_ADDR
Andrew Cagney
ac131313@redhat.com
Mon Oct 21 12:08:00 GMT 2002
> /* Don't cause a memory_error when accessing sigcontext in case the stack
> layout has changed or the stack is corrupt. */
> target_read_memory (sigcontext_addr + SIGCONTEXT_PC_OFFSET, buf, ptrbytes);
> - return extract_unsigned_integer (buf, ptrbytes);
> + return extract_typed_address (buf, builtin_type_void_data_ptr);
This should be builtin_type_void_code_ptr since it is extracting a code
pointer (the PC). It, also, might as well use read_memory_typed_address().
Andrew
More information about the Gdb-patches
mailing list