This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Fix hash table mixup in bfd_simple_get_relocated_section_content


Andrew Cagney <ac131313@redhat.com> writes:


Daniel Jacobowitz <drow@mvista.com> writes:


On Wed, Sep 17, 2003 at 06:04:05PM +0200, Andreas Schwab wrote:



bfd_simple_get_relocated_section_content uses the generic linker
interface, so it should also use the generic_link_hash_table.




Hmm, this seems right to me.

Posted now to binutils@ where it belongs, but I think this should be
added to gdb-6.0 because it also affects add-symbol.


Grrrr :-)


What's the damage without it?


You can get random crashes in generic_link_add_symbol_list because
_bfd_generic_link_add_one_symbol hands out a bfd_link_hash_entry, but a
generic_link_hash_entry is expected, and h->sym remains uninitialized.
The specific case where it happend was gdb debugging a user mode linux
process, and applying add-symbol to a kernel module.

If you can extract a "safe for GDB's branch" from Nick or Alan then it's approved.


Andrew



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]