diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2006-02-10 15:04:19 +0000 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2006-02-10 15:04:19 +0000 |
commit | 84d1d6507cd684f6c517bd4d5056128b3fc7ef71 (patch) | |
tree | c68b98adc7bbb406424c061fe57dc00dc9428c8b /binutils | |
parent | 70e45ad9bb4476368d66997ec0df94abc9d3a2de (diff) | |
download | gdb-84d1d6507cd684f6c517bd4d5056128b3fc7ef71.zip gdb-84d1d6507cd684f6c517bd4d5056128b3fc7ef71.tar.gz gdb-84d1d6507cd684f6c517bd4d5056128b3fc7ef71.tar.bz2 |
bfd/
2006-02-10 H.J. Lu <hongjiu.lu@intel.com>
PR binutils/2258
* elf.c (copy_private_bfd_data): Renamed to ...
(rewrite_elf_program_header): This.
(copy_elf_program_header): New function.
(copy_private_bfd_data): Likewise.
binutils/
2006-02-10 H.J. Lu <hongjiu.lu@intel.com>
PR binutils/2258
* readelf.c (process_program_headers): Use
ELF_IS_SECTION_IN_SEGMENT_MEMORY.
include/elf/
2006-02-10 H.J. Lu <hongjiu.lu@intel.com>
PR binutils/2258
* internal.h (ELF_IS_SECTION_IN_SEGMENT_FILE): New.
(ELF_IS_SECTION_IN_SEGMENT_MEMORY): Likewise.
Diffstat (limited to 'binutils')
-rw-r--r-- | binutils/ChangeLog | 6 | ||||
-rw-r--r-- | binutils/readelf.c | 19 |
2 files changed, 7 insertions, 18 deletions
diff --git a/binutils/ChangeLog b/binutils/ChangeLog index 982523a..90257f8 100644 --- a/binutils/ChangeLog +++ b/binutils/ChangeLog @@ -1,3 +1,9 @@ +2006-02-10 H.J. Lu <hongjiu.lu@intel.com> + + PR binutils/2258 + * readelf.c (process_program_headers): Use + ELF_IS_SECTION_IN_SEGMENT_MEMORY. + 2006-02-09 Eric Botcazou <ebotcazou@libertysurf.fr> * configure.in (CHECK_DECLS): Add snprintf and vsnprintf. diff --git a/binutils/readelf.c b/binutils/readelf.c index a10dc41..208b6d4 100644 --- a/binutils/readelf.c +++ b/binutils/readelf.c @@ -3447,24 +3447,7 @@ process_program_headers (FILE *file) for (j = 1; j < elf_header.e_shnum; j++, section++) { - if (section->sh_size > 0 - /* PT_TLS segment contains only SHF_TLS sections. */ - && (segment->p_type != PT_TLS - || (section->sh_flags & SHF_TLS) != 0) - /* Compare allocated sections by VMA, unallocated - sections by file offset. */ - && (section->sh_flags & SHF_ALLOC - ? (section->sh_addr >= segment->p_vaddr - && section->sh_addr + section->sh_size - <= segment->p_vaddr + segment->p_memsz) - : ((bfd_vma) section->sh_offset >= segment->p_offset - && (section->sh_offset + section->sh_size - <= segment->p_offset + segment->p_filesz))) - /* .tbss is special. It doesn't contribute memory space - to normal segments. */ - && (!((section->sh_flags & SHF_TLS) != 0 - && section->sh_type == SHT_NOBITS) - || segment->p_type == PT_TLS)) + if (ELF_IS_SECTION_IN_SEGMENT_MEMORY(section, segment)) printf ("%s ", SECTION_NAME (section)); } |