diff options
author | Alan Modra <amodra@bigpond.net.au> | 2000-09-29 07:01:18 +0000 |
---|---|---|
committer | Alan Modra <amodra@bigpond.net.au> | 2000-09-29 07:01:18 +0000 |
commit | 8707a5770abf2bfe41026a9e96988b0cf76dbaa7 (patch) | |
tree | cb61c8c3d5426e9293a66561cc7324b50b931850 /bfd | |
parent | 02d24c013f727e5644f35e7d30f7d6d7ff4e7156 (diff) | |
download | binutils-redhat-8707a5770abf2bfe41026a9e96988b0cf76dbaa7.tar.gz |
(elf_fake_sections): Do not mark the section SHT_NOBITS if
is has the SEC_HAS_CONTENTS flag set.
Diffstat (limited to 'bfd')
-rw-r--r-- | bfd/ChangeLog | 5 | ||||
-rw-r--r-- | bfd/elf.c | 10 |
2 files changed, 7 insertions, 8 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog index bc4f246c04..1f81b532c2 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,8 @@ +2000-09-29 Momchil Velikov <velco@fadata.bg> + + * elf.c (elf_fake_sections): Do not mark the section SHT_NOBITS if + is has the SEC_HAS_CONTENTS flag set. + 2000-09-28 Örjan Friberg <orjanf@axis.com> Hans-Peter Nilsson <hp@axis.com> @@ -1787,16 +1787,10 @@ elf_fake_sections (abfd, asect, failedptrarg) || this_hdr->sh_info == elf_tdata (abfd)->cverrefs); } else if ((asect->flags & SEC_ALLOC) != 0 - && (asect->flags & SEC_LOAD) != 0) - this_hdr->sh_type = SHT_PROGBITS; - else if ((asect->flags & SEC_ALLOC) != 0 - && ((asect->flags & SEC_LOAD) == 0)) + && ((asect->flags & (SEC_LOAD | SEC_HAS_CONTENTS) == 0))) this_hdr->sh_type = SHT_NOBITS; else - { - /* Who knows? */ - this_hdr->sh_type = SHT_PROGBITS; - } + this_hdr->sh_type = SHT_PROGBITS; if ((asect->flags & SEC_ALLOC) != 0) this_hdr->sh_flags |= SHF_ALLOC; |