summaryrefslogtreecommitdiff
path: root/ld/plugin.c
diff options
context:
space:
mode:
authorDave Korn <dave.korn@artimi.com>2010-10-20 17:01:05 +0000
committerDave Korn <dave.korn@artimi.com>2010-10-20 17:01:05 +0000
commitf2b6d1ce1e7bf9b010077749db8cbcdfa4ade59f (patch)
treed9ef681a6918b25f851cf51250f0578b51007699 /ld/plugin.c
parent72a32367867edcd1695de21aeb20f7677c7fcfa4 (diff)
downloadbinutils-redhat-f2b6d1ce1e7bf9b010077749db8cbcdfa4ade59f.tar.gz
* plugin.c (get_symbols): Check symbol type correctly.
Diffstat (limited to 'ld/plugin.c')
-rw-r--r--ld/plugin.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ld/plugin.c b/ld/plugin.c
index c1961c54f4..efc520f707 100644
--- a/ld/plugin.c
+++ b/ld/plugin.c
@@ -417,7 +417,7 @@ get_symbols (const void *handle, int nsyms, struct ld_plugin_symbol *syms)
if (syms[n].def == LDPK_UNDEF || syms[n].def == LDPK_WEAKUNDEF
|| syms[n].def == LDPK_COMMON)
{
- asection *owner_sec = (syms[n].def == LDPK_COMMON)
+ asection *owner_sec = (blhe->type == bfd_link_hash_common)
? blhe->u.c.p->section
: blhe->u.def.section;
if (owner_sec->owner == link_info.output_bfd)