aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf32-xstormy16.c
diff options
context:
space:
mode:
Diffstat (limited to 'bfd/elf32-xstormy16.c')
-rw-r--r--bfd/elf32-xstormy16.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/bfd/elf32-xstormy16.c b/bfd/elf32-xstormy16.c
index bdb0279..484acdd 100644
--- a/bfd/elf32-xstormy16.c
+++ b/bfd/elf32-xstormy16.c
@@ -500,6 +500,9 @@ xstormy16_relax_plt_check (h, xdata)
{
struct relax_plt_data *data = (struct relax_plt_data *) xdata;
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
if (h->plt.offset != (bfd_vma) -1)
{
bfd_vma address;
@@ -533,6 +536,9 @@ xstormy16_relax_plt_realloc (h, xdata)
{
bfd_vma *entry = (bfd_vma *) xdata;
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
if (h->plt.offset != (bfd_vma) -1)
{
h->plt.offset = *entry;