diff options
author | Alan Modra <amodra@gmail.com> | 2007-11-12 03:28:52 +0000 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2007-11-12 03:28:52 +0000 |
commit | 8f39ba8ef25ad65f372ac4ce6974804e898e2c0a (patch) | |
tree | c0dad7045eb7d04543dd779e1d88756fdc91b182 /bfd/elf.c | |
parent | 2c524891fc22f292c02467c99ebb5a1615f84f6e (diff) | |
download | gdb-8f39ba8ef25ad65f372ac4ce6974804e898e2c0a.zip gdb-8f39ba8ef25ad65f372ac4ce6974804e898e2c0a.tar.gz gdb-8f39ba8ef25ad65f372ac4ce6974804e898e2c0a.tar.bz2 |
* elf.c (_bfd_elf_get_synthetic_symtab): Only bump the symbol
pointer when we have a valid symbol. Init udata.p to NULL.
Diffstat (limited to 'bfd/elf.c')
-rw-r--r-- | bfd/elf.c | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -8678,7 +8678,7 @@ _bfd_elf_get_synthetic_symtab (bfd *abfd, names = (char *) (s + count); p = relplt->relocation; n = 0; - for (i = 0; i < count; i++, s++, p++) + for (i = 0; i < count; i++, p++) { size_t len; bfd_vma addr; @@ -8695,12 +8695,13 @@ _bfd_elf_get_synthetic_symtab (bfd *abfd, s->section = plt; s->value = addr - plt->vma; s->name = names; + s->udata.p = NULL; len = strlen ((*p->sym_ptr_ptr)->name); memcpy (names, (*p->sym_ptr_ptr)->name, len); names += len; memcpy (names, "@plt", sizeof ("@plt")); names += sizeof ("@plt"); - ++n; + ++s, ++n; } return n; |