* elf32-arm.c (elf32_arm_output_arch_local_syms): Do not add
authorDaniel Jacobowitz <drow@false.org>
Wed, 3 Mar 2010 17:56:24 +0000 (17:56 +0000)
committerDaniel Jacobowitz <drow@false.org>
Wed, 3 Mar 2010 17:56:24 +0000 (17:56 +0000)
a mapping symbol to an empty section.

bfd/ChangeLog
bfd/elf32-arm.c

index d1ce00c365db797c8adc78cb3621c377129aeffb..f592fbb1d0ab7ba87d79fa42c4c48f78db218744 100644 (file)
@@ -1,3 +1,8 @@
+2010-03-03  Daniel Jacobowitz  <dan@codesourcery.com>
+
+       * elf32-arm.c (elf32_arm_output_arch_local_syms): Do not add
+       a mapping symbol to an empty section.
+
 2010-03-02  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
 
        * elf32-arm.c (elf32_arm_merge_eabi_attributes): Add a check of the
index 29fb29580f3e0cda5de5f65702766e18f404cd41..c2a9987b83b6d0e3aa0aff2ea5d4a65575509e31 100644 (file)
@@ -13175,7 +13175,8 @@ elf32_arm_output_arch_local_syms (bfd *output_bfd,
                && (osi.sec->flags & (SEC_HAS_CONTENTS | SEC_LINKER_CREATED))
                   == SEC_HAS_CONTENTS
                && get_arm_elf_section_data (osi.sec) != NULL
-               && get_arm_elf_section_data (osi.sec)->mapcount == 0)
+               && get_arm_elf_section_data (osi.sec)->mapcount == 0
+               && osi.sec->size > 0)
              {
                osi.sec_shndx = _bfd_elf_section_from_bfd_section
                  (output_bfd, osi.sec->output_section);