forked from Imagelibrary/binutils-gdb
* elfcore.h (elf_core_file_p): Ensure we have a backend match
with the correct arch size before rejecting the generic fallback. * elfcode.h (elf_object_p): Likewise. Ensure arch size matches before accepting a target.
This commit is contained in:
@@ -159,6 +159,8 @@ elf_core_file_p (bfd *abfd)
|
||||
if ((*target_ptr)->flavour != bfd_target_elf_flavour)
|
||||
continue;
|
||||
back = xvec_get_elf_backend_data (*target_ptr);
|
||||
if (back->s->arch_size != ARCH_SIZE)
|
||||
continue;
|
||||
if (back->elf_machine_code == i_ehdrp->e_machine
|
||||
|| (back->elf_machine_alt1 != 0
|
||||
&& i_ehdrp->e_machine == back->elf_machine_alt1)
|
||||
|
||||
Reference in New Issue
Block a user