aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf32-hppa.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2005-08-18 01:28:26 +0000
committerAlan Modra <amodra@gmail.com>2005-08-18 01:28:26 +0000
commit909272ee76c4915692763a3dde6b4b1dc21fc166 (patch)
treeb3d5d745bbc0cc2085cb20c4d952ba95ae0380e9 /bfd/elf32-hppa.c
parent11bcca22f4e218e248dceb797fd92947004bcf9c (diff)
downloadgdb-909272ee76c4915692763a3dde6b4b1dc21fc166.zip
gdb-909272ee76c4915692763a3dde6b4b1dc21fc166.tar.gz
gdb-909272ee76c4915692763a3dde6b4b1dc21fc166.tar.bz2
* elf-m10300.c (_bfd_mn10300_elf_adjust_dynamic_symbol): Warn on
zero size dynamic variables. * elf32-arm.c (elf32_arm_adjust_dynamic_symbol): Likewise. * elf32-cris.c (elf_cris_adjust_dynamic_symbol): Likewise. * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Likewise. * elf32-i370.c (i370_elf_adjust_dynamic_symbol): Likewise. * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Likewise. * elf32-m32r.c (m32r_elf_adjust_dynamic_symbol): Likewise. * elf32-m68k.c (elf_m68k_adjust_dynamic_symbol): Likewise. * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise. * elf32-s390.c (elf_s390_adjust_dynamic_symbol): Likewise. * elf32-sh.c (sh_elf_adjust_dynamic_symbol): Likewise. * elf32-vax.c (elf_vax_adjust_dynamic_symbol): Likewise. * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise. * elf64-s390.c (elf_s390_adjust_dynamic_symbol): Likewise. * elf64-sh64.c (sh64_elf64_adjust_dynamic_symbol): Likewise. * elf64-x86-64.c (elf64_x86_64_adjust_dynamic_symbol): Likewise. * elfxx-sparc.c (_bfd_sparc_elf_adjust_dynamic_symbol): Likewise.
Diffstat (limited to 'bfd/elf32-hppa.c')
-rw-r--r--bfd/elf32-hppa.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/bfd/elf32-hppa.c b/bfd/elf32-hppa.c
index e3c45ec..7f20bd6 100644
--- a/bfd/elf32-hppa.c
+++ b/bfd/elf32-hppa.c
@@ -1807,6 +1807,13 @@ elf32_hppa_adjust_dynamic_symbol (struct bfd_link_info *info,
}
}
+ if (eh->size == 0)
+ {
+ (*_bfd_error_handler) (_("dynamic variable `%s' is zero size"),
+ eh->root.root.string);
+ return TRUE;
+ }
+
/* We must allocate the symbol in our .dynbss section, which will
become part of the .bss section of the executable. There will be
an entry for this symbol in the .dynsym section. The dynamic