diff options
author | Alan Modra <amodra@gmail.com> | 2006-06-13 14:49:54 +0000 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2006-06-13 14:49:54 +0000 |
commit | 4f87808cf30abce4230a81277a2ab88e5d831cfc (patch) | |
tree | 0de8d1b88e17c07537b989f90964358fe40ae64e /bfd | |
parent | 54d1c879c12b2791f0bc2847b382ff6a9849cc18 (diff) | |
download | gdb-4f87808cf30abce4230a81277a2ab88e5d831cfc.zip gdb-4f87808cf30abce4230a81277a2ab88e5d831cfc.tar.gz gdb-4f87808cf30abce4230a81277a2ab88e5d831cfc.tar.bz2 |
* elflink.c (elf_link_add_object_symbols): Save and restore
struct bfd_hash_table table, size and count fields for
as-needed libs.
Diffstat (limited to 'bfd')
-rw-r--r-- | bfd/ChangeLog | 6 | ||||
-rw-r--r-- | bfd/elflink.c | 9 |
2 files changed, 15 insertions, 0 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog index 8a369c8..5090a01 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,9 @@ +2006-06-14 Alan Modra <amodra@bigpond.net.au> + + * elflink.c (elf_link_add_object_symbols): Save and restore + struct bfd_hash_table table, size and count fields for + as-needed libs. + 2006-06-12 Thiemo Seufer <ths@mips.com> * elf32-mips.c: Expand comment about ABI-mandated pagesize values. diff --git a/bfd/elflink.c b/bfd/elflink.c index f4c63f4..0a32963 100644 --- a/bfd/elflink.c +++ b/bfd/elflink.c @@ -3080,6 +3080,9 @@ elf_link_add_object_symbols (bfd *abfd, struct bfd_link_info *info) struct elf_link_hash_table *htab; bfd_size_type amt; void *alloc_mark = NULL; + struct bfd_hash_entry **old_table = NULL; + unsigned int old_size = 0; + unsigned int old_count = 0; void *old_tab = NULL; void *old_hash; void *old_ent; @@ -3504,6 +3507,9 @@ elf_link_add_object_symbols (bfd *abfd, struct bfd_link_info *info) memcpy (old_hash, sym_hash, hashsize); old_undefs = htab->root.undefs; old_undefs_tail = htab->root.undefs_tail; + old_table = htab->root.table.table; + old_size = htab->root.table.size; + old_count = htab->root.table.count; old_dynsymcount = htab->dynsymcount; for (i = 0; i < htab->root.table.size; i++) @@ -4151,6 +4157,9 @@ elf_link_add_object_symbols (bfd *abfd, struct bfd_link_info *info) old_hash = (char *) old_tab + tabsize; old_ent = (char *) old_hash + hashsize; sym_hash = elf_sym_hashes (abfd); + htab->root.table.table = old_table; + htab->root.table.size = old_size; + htab->root.table.count = old_count; memcpy (htab->root.table.table, old_tab, tabsize); memcpy (sym_hash, old_hash, hashsize); htab->root.undefs = old_undefs; |