Fix "set architecture mips:10000" crash
[deliverable/binutils-gdb.git] / gdb / mips-tdep.c
index 63c1560f568c849838933bff8f154606cd2642e4..178a163cae9f6067f8c5de23a4a9ddbd4f34f5b3 100644 (file)
@@ -8433,7 +8433,8 @@ mips_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
          /* On Irix, ELF64 executables use the N64 ABI.  The
             pseudo-sections which describe the ABI aren't present
             on IRIX.  (Even for executables created by gcc.)  */
-         if (bfd_get_flavour (info.abfd) == bfd_target_elf_flavour
+         if (info.abfd != NULL
+             && bfd_get_flavour (info.abfd) == bfd_target_elf_flavour
              && elf_elfheader (info.abfd)->e_ident[EI_CLASS] == ELFCLASS64)
            found_abi = MIPS_ABI_N64;
          else
This page took 0.025433 seconds and 4 git commands to generate.