From a8ad78a74eb4e3bf77cf6174e5c10a3c30212b3a Mon Sep 17 00:00:00 2001 From: Alan Modra Date: Mon, 10 Aug 2009 07:24:33 +0000 Subject: [PATCH] * elf32-ppc.c (ppc_elf_relax_section): Ignore non-code sections. --- bfd/ChangeLog | 4 ++++ bfd/elf32-ppc.c | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/bfd/ChangeLog b/bfd/ChangeLog index 8d103cd945..cc9850c4af 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,7 @@ +2009-08-10 Alan Modra + + * elf32-ppc.c (ppc_elf_relax_section): Ignore non-code sections. + 2009-08-10 Alan Modra * elflink.c (_bfd_elf_adjust_dynamic_symbol): Don't clear plt diff --git a/bfd/elf32-ppc.c b/bfd/elf32-ppc.c index 542928d4d4..292503945c 100644 --- a/bfd/elf32-ppc.c +++ b/bfd/elf32-ppc.c @@ -5905,8 +5905,9 @@ ppc_elf_relax_section (bfd *abfd, *again = FALSE; /* Nothing to do if there are no relocations, and no need to do - anything with non-alloc sections. */ + anything with non-alloc or non-code sections. */ if ((isec->flags & SEC_ALLOC) == 0 + || (isec->flags & SEC_CODE) == 0 || (isec->flags & SEC_RELOC) == 0 || isec->reloc_count == 0) return TRUE; -- 2.34.1