From 25bbc984802ebed8906adb1abbb9cb72aadf6a6e Mon Sep 17 00:00:00 2001 From: "H.J. Lu" Date: Tue, 13 Dec 2005 15:34:28 +0000 Subject: 2005-12-13 H.J. Lu PR ld/2008 * elf.c (_bfd_elf_setup_sections): Return FALSE if elf_linked_to_section will be set to NULL. * format.c (bfd_check_format_matches): Don't check the default target twice. --- bfd/format.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'bfd/format.c') diff --git a/bfd/format.c b/bfd/format.c index ba9ca9f6095..6a34dd2bea4 100644 --- a/bfd/format.c +++ b/bfd/format.c @@ -217,7 +217,9 @@ bfd_check_format_matches (bfd *abfd, bfd_format format, char ***matching) const bfd_target *temp; bfd_error_type err; - if (*target == &binary_vec) + /* Don't check the default target twice. */ + if (*target == &binary_vec + || (!abfd->target_defaulted && *target == save_targ)) continue; abfd->xvec = *target; /* Change BFD's target temporarily. */ -- cgit v1.2.1