aboutsummaryrefslogtreecommitdiff
path: root/bfd/elflink.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2015-02-17 07:18:15 +1030
committerAlan Modra <amodra@gmail.com>2015-02-19 14:14:52 +1030
commitcf18fda46276a088b0b2ee60a84f8670de2ef4c0 (patch)
tree62bb8403e627b031e62e6ac889f7953bedc239f3 /bfd/elflink.c
parent5c9352f317d63cab0ebe512a8461e5256b6a913b (diff)
downloadgdb-cf18fda46276a088b0b2ee60a84f8670de2ef4c0.zip
gdb-cf18fda46276a088b0b2ee60a84f8670de2ef4c0.tar.gz
gdb-cf18fda46276a088b0b2ee60a84f8670de2ef4c0.tar.bz2
tidy _bfd_elf_define_linkage_sym
* elflink.c (_bfd_elf_define_linkage_sym): Set 'bed' earlier.
Diffstat (limited to 'bfd/elflink.c')
-rw-r--r--bfd/elflink.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/bfd/elflink.c b/bfd/elflink.c
index 0cd85f1..ec1e4df 100644
--- a/bfd/elflink.c
+++ b/bfd/elflink.c
@@ -77,9 +77,9 @@ _bfd_elf_define_linkage_sym (bfd *abfd,
}
bh = &h->root;
+ bed = get_elf_backend_data (abfd);
if (!_bfd_generic_link_add_one_symbol (info, abfd, name, BSF_GLOBAL,
- sec, 0, NULL, FALSE,
- get_elf_backend_data (abfd)->collect,
+ sec, 0, NULL, FALSE, bed->collect,
&bh))
return NULL;
h = (struct elf_link_hash_entry *) bh;
@@ -90,7 +90,6 @@ _bfd_elf_define_linkage_sym (bfd *abfd,
if (ELF_ST_VISIBILITY (h->other) != STV_INTERNAL)
h->other = (h->other & ~ELF_ST_VISIBILITY (-1)) | STV_HIDDEN;
- bed = get_elf_backend_data (abfd);
(*bed->elf_backend_hide_symbol) (info, h, TRUE);
return h;
}