aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf32-sh.c
diff options
context:
space:
mode:
Diffstat (limited to 'bfd/elf32-sh.c')
-rw-r--r--bfd/elf32-sh.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/bfd/elf32-sh.c b/bfd/elf32-sh.c
index eec9642..35ebf1a 100644
--- a/bfd/elf32-sh.c
+++ b/bfd/elf32-sh.c
@@ -3216,6 +3216,7 @@ sh_elf_relocate_section (output_bfd, info, input_bfd, input_section,
case R_SH_DIR32:
case R_SH_REL32:
if (info->shared
+ && r_symndx != 0
&& (input_section->flags & SEC_ALLOC) != 0
&& (r_type != R_SH_REL32
|| (h != NULL