PT_GNU_MBIND section mapping

* elf/internal.h (ELF_SECTION_IN_SEGMENT_1): Exclude non-alloc
	sections in GNU_MBIND segments.
This commit is contained in:
Alan Modra
2019-07-24 15:03:49 +09:30
parent 024a584000
commit 7137a1ed0a
2 changed files with 8 additions and 1 deletions

View File

@@ -330,8 +330,10 @@ struct elf_segment_map
&& ((segment)->p_type == PT_LOAD \
|| (segment)->p_type == PT_DYNAMIC \
|| (segment)->p_type == PT_GNU_EH_FRAME \
|| (segment)->p_type == PT_GNU_STACK \
|| (segment)->p_type == PT_GNU_RELRO \
|| (segment)->p_type == PT_GNU_STACK)) \
|| ((segment)->p_type >= PT_GNU_MBIND_LO \
&& (segment)->p_type <= PT_GNU_MBIND_HI))) \
/* Any section besides one of type SHT_NOBITS must have file \
offsets within the segment. */ \
&& ((sec_hdr)->sh_type == SHT_NOBITS \