summaryrefslogtreecommitdiff
path: root/bfd/elfn32-mips.c
diff options
context:
space:
mode:
authorMaciej W. Rozycki <macro@linux-mips.org>2012-12-03 16:33:12 +0000
committerMaciej W. Rozycki <macro@linux-mips.org>2012-12-03 16:33:12 +0000
commit1cc5e9e8b878b9e248fc73c7f672687638f85d8f (patch)
treed73d48bce8b2b675a1661012199803e79405640e /bfd/elfn32-mips.c
parent33cb715949ad310c5e391e3a0cb89639032cf51f (diff)
downloadbinutils-redhat-1cc5e9e8b878b9e248fc73c7f672687638f85d8f.tar.gz
* elf32-mips.c (mips_elf32_object_p): Return right away when the
ABI is not compatible. * elfn32-mips.c (mips_elf_n32_object_p): Likewise.
Diffstat (limited to 'bfd/elfn32-mips.c')
-rw-r--r--bfd/elfn32-mips.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/bfd/elfn32-mips.c b/bfd/elfn32-mips.c
index 7c3ca7d8d6..08c8e5faec 100644
--- a/bfd/elfn32-mips.c
+++ b/bfd/elfn32-mips.c
@@ -3165,6 +3165,9 @@ mips_elf_n32_object_p (bfd *abfd)
{
unsigned long mach;
+ if (!ABI_N32_P (abfd))
+ return FALSE;
+
/* Irix 5 and 6 are broken. Object file symbol tables are not always
sorted correctly such that local symbols precede global symbols,
and the sh_info field in the symbol table is not always right. */
@@ -3173,10 +3176,6 @@ mips_elf_n32_object_p (bfd *abfd)
mach = _bfd_elf_mips_mach (elf_elfheader (abfd)->e_flags);
bfd_default_set_arch_mach (abfd, bfd_arch_mips, mach);
-
- if (! ABI_N32_P(abfd))
- return FALSE;
-
return TRUE;
}