Fix GDB crash while trying to display the return type of a JIT frame.

Pedro Alves palves@redhat.com
Tue Jun 5 15:38:00 GMT 2012


On 06/04/2012 09:45 PM, Kaushik Srenevasan wrote:

> @@ -672,6 +672,7 @@ finalize_symtab (struct gdb_symtab *stab, struct objfile *objfile)
>        SYMBOL_DOMAIN (block_name) = VAR_DOMAIN;
>        SYMBOL_CLASS (block_name) = LOC_BLOCK;
>        SYMBOL_SYMTAB (block_name) = symtab;
> +      SYMBOL_TYPE (block_name) = lookup_function_type(arch_type(target_gdbarch, TYPE_CODE_VOID, 1, "void"));


Pedantically, it'd be better to write 'get_objfile_arch (objfile)' instead
of target_gdbarch, even though the objfile's gdbarch is initialized
to target_gdbarch presently.

-- 
Pedro Alves



More information about the Gdb-patches mailing list