aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2003-08-23 04:10:34 +0000
committerAlan Modra <amodra@gmail.com>2003-08-23 04:10:34 +0000
commit40a0491a90506be953114a472d7562c7afb5b600 (patch)
tree3184100d75375a5ef049d41f96cde5cc2ce19f05 /bfd
parent4be5d5207ca013d5a5fb2bdf7cb5de1c93d2892e (diff)
downloadgdb-40a0491a90506be953114a472d7562c7afb5b600.zip
gdb-40a0491a90506be953114a472d7562c7afb5b600.tar.gz
gdb-40a0491a90506be953114a472d7562c7afb5b600.tar.bz2
* elflink.h (elf_link_add_object_symbols): Don't crash on NULL owner.
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog20
-rw-r--r--bfd/elflink.h3
2 files changed, 14 insertions, 9 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 80ba095..0848f26 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,7 @@
+2003-08-23 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_link_add_object_symbols): Don't crash on NULL owner.
+
2003-08-22 H.J. Lu <hongjiu.lu@intel.com>
* elfxx-ia64.c (elfNN_ia64_create_dynamic_sections): Align the
@@ -27,9 +31,9 @@
replace some duplicated code in most elfxx-xxxx.c files. This
version uses the new fields in bfd_link_info.
- * elf-m10300.c (mn10300_elf_relocate_section): Use new macro.
- * elf32-arm.h (elf32_arm_relocate_section): Likewise.
- * elf32-cris.c (cris_elf_relocate_section): Likewise.
+ * elf-m10300.c (mn10300_elf_relocate_section): Use new macro.
+ * elf32-arm.h (elf32_arm_relocate_section): Likewise.
+ * elf32-cris.c (cris_elf_relocate_section): Likewise.
* elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
* elf32-i386.c (elf_i386_relocate_section): Likewise.
* elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
@@ -46,8 +50,8 @@
* elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
* elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
* elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
-
- * elf-hppa.h (elf_hppa_unmark_useless_dynamic_symbols,
+
+ * elf-hppa.h (elf_hppa_unmark_useless_dynamic_symbols,
elf_hppa_remark_useless_dynamic_symbols,
elf_hppa_relocate_section): Use the new fields in
bfd_link_info structure.
@@ -59,9 +63,9 @@
* elfxx-mips.c (mips_elf_calculate_relocation): Likewise.
* elflink.h (elf_link_output_extsym): Fix test for reporting
- undefined symbols in shared libraries. Remove redundant test
- of shlib_undefined when reporting references to forced local
- symbols.
+ undefined symbols in shared libraries. Remove redundant test
+ of shlib_undefined when reporting references to forced local
+ symbols.
2003-08-18 Andreas Schwab <schwab@suse.de>
diff --git a/bfd/elflink.h b/bfd/elflink.h
index d667993..48b86cf 100644
--- a/bfd/elflink.h
+++ b/bfd/elflink.h
@@ -1186,7 +1186,8 @@ elf_link_add_object_symbols (bfd *abfd, struct bfd_link_info *info)
bfd *common_bfd;
symbol_align = ffs (h->root.u.def.value) - 1;
- if ((h->root.u.def.section->owner->flags & DYNAMIC) == 0)
+ if (h->root.u.def.section->owner != NULL
+ && (h->root.u.def.section->owner->flags & DYNAMIC) == 0)
{
normal_align = h->root.u.def.section->alignment_power;
if (normal_align > symbol_align)