diff options
author | Alan Modra <amodra@gmail.com> | 2005-02-03 13:54:30 +0000 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2005-02-03 13:54:30 +0000 |
commit | 10d86c8a5c3965bfcc895c7e6a624cd3fd6e240d (patch) | |
tree | 3f0eb8eea7ceeccba1d7d410353b6330462b0495 | |
parent | 464dd14d58f648ec577fda6004708c385e3084a3 (diff) | |
download | gdb-10d86c8a5c3965bfcc895c7e6a624cd3fd6e240d.zip gdb-10d86c8a5c3965bfcc895c7e6a624cd3fd6e240d.tar.gz gdb-10d86c8a5c3965bfcc895c7e6a624cd3fd6e240d.tar.bz2 |
* linker.c (_bfd_link_hash_newfunc): Set all local fields.
-rw-r--r-- | bfd/ChangeLog | 4 | ||||
-rw-r--r-- | bfd/linker.c | 4 |
2 files changed, 7 insertions, 1 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog index 21e8a92..72eaad8 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,5 +1,9 @@ 2005-02-03 Alan Modra <amodra@bigpond.net.au> + * linker.c (_bfd_link_hash_newfunc): Set all local fields. + +2005-02-03 Alan Modra <amodra@bigpond.net.au> + * linker.c (_bfd_generic_link_add_one_symbol): Set u.undef.weak. * elflink.c (elf_smash_syms): Restore symbols that were undefweak before the as-needed lib was loaded. Abort on unexpected refs. diff --git a/bfd/linker.c b/bfd/linker.c index 5868b95..f940d32 100644 --- a/bfd/linker.c +++ b/bfd/linker.c @@ -455,7 +455,9 @@ _bfd_link_hash_newfunc (struct bfd_hash_entry *entry, /* Initialize the local fields. */ h->type = bfd_link_hash_new; - h->u.undef.next = NULL; + memset (&h->u.undef.next, 0, + (sizeof (struct bfd_link_hash_entry) + - offsetof (struct bfd_link_hash_entry, u.undef.next))); } return entry; |