From 4c1534c7a2ada64894ab0ef684dfec3bc73beef7 Mon Sep 17 00:00:00 2001 From: Alan Modra Date: Thu, 22 Jul 2010 14:07:10 +0000 Subject: [PATCH] * aoutx.h (some_aout_object_p): Don't set EXEC_P for files with relocs. --- bfd/ChangeLog | 5 +++++ bfd/aoutx.h | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/bfd/ChangeLog b/bfd/ChangeLog index aa36284..5e5efb0 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,8 @@ +2010-07-22 Alan Modra + + * aoutx.h (some_aout_object_p): Don't set EXEC_P for files with + relocs. + 2010-07-20 Alan Modra * elf.c (assign_file_positions_for_load_sections): Check that diff --git a/bfd/aoutx.h b/bfd/aoutx.h index c3366b6..c632722 100644 --- a/bfd/aoutx.h +++ b/bfd/aoutx.h @@ -629,7 +629,9 @@ NAME (aout, some_aout_object_p) (bfd *abfd, if (execp->a_entry != 0 || (execp->a_entry >= obj_textsec (abfd)->vma && execp->a_entry < (obj_textsec (abfd)->vma - + obj_textsec (abfd)->size))) + + obj_textsec (abfd)->size) + && execp->a_trsize == 0 + && execp->a_drsize == 0)) abfd->flags |= EXEC_P; #ifdef STAT_FOR_EXEC else -- 2.7.4