aboutsummaryrefslogtreecommitdiff
path: root/bfd/elflink.h
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>1999-08-31 14:07:27 +0000
committerNick Clifton <nickc@redhat.com>1999-08-31 14:07:27 +0000
commit994819d26757a1ce375ea08045bc3ba0eafa11e9 (patch)
treeb3485ecef014842ab67d56b071ecc13ea9ce766d /bfd/elflink.h
parentafb478e8cd1b94169dabb1da373277e38b27ee6e (diff)
downloadgdb-994819d26757a1ce375ea08045bc3ba0eafa11e9.zip
gdb-994819d26757a1ce375ea08045bc3ba0eafa11e9.tar.gz
gdb-994819d26757a1ce375ea08045bc3ba0eafa11e9.tar.bz2
When possible, keep the original type of the symbol.
Diffstat (limited to 'bfd/elflink.h')
-rw-r--r--bfd/elflink.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/bfd/elflink.h b/bfd/elflink.h
index f6727a6..be38fb9 100644
--- a/bfd/elflink.h
+++ b/bfd/elflink.h
@@ -2371,7 +2371,10 @@ NAME(bfd_elf,record_link_assignment) (output_bfd, info, name, provide)
h->verinfo.verdef = NULL;
h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR;
- h->type = STT_OBJECT;
+
+ /* When possible, keep the original type of the symbol */
+ if (h->type == STT_NOTYPE)
+ h->type = STT_OBJECT;
if (((h->elf_link_hash_flags & (ELF_LINK_HASH_DEF_DYNAMIC
| ELF_LINK_HASH_REF_DYNAMIC)) != 0