Convert elfread.c to type-safe registry API
authorTom Tromey <tom@tromey.com>
Wed, 1 May 2019 21:41:13 +0000 (15:41 -0600)
committerTom Tromey <tom@tromey.com>
Wed, 8 May 2019 22:01:54 +0000 (16:01 -0600)
commit8127a2fab5780f27a1c9998b0be4d8b5c28c1603
tree7dd8adffbea1256e5819365d48a46644e874d030
parent91d3055d8b77d56cf64f85ace4237a0ccca98a4a
Convert elfread.c to type-safe registry API

This changes elfread.c to use the type-safe registry API.  This also
fixes a potential memory leak, by changing the hash table so that it
is no longer allocated on an obstack.

gdb/ChangeLog
2019-05-08  Tom Tromey  <tom@tromey.com>

* elfread.c (elf_objfile_gnu_ifunc_cache_data): Change type.
(elf_gnu_ifunc_record_cache): Update.  Don't allocate hash table
on obstack.
(elf_gnu_ifunc_resolve_by_cache, _initialize_elfread): Update.
gdb/ChangeLog
gdb/elfread.c