Lines Matching refs:sh_entsize
639 size_t sh_entsize = gelf_fsize (ebl->elf, ELF_T_SYM, 1, EV_CURRENT); in check_symtab() local
640 if (shdr->sh_entsize != sh_entsize) in check_symtab()
678 for (size_t cnt = 1; cnt < shdr->sh_size / sh_entsize; ++cnt) in check_symtab()
1077 if (rcshdr->sh_type == SHT_DYNAMIC && rcshdr->sh_entsize != 0) in is_rel_dyn()
1088 for (cnt = 1; cnt < rcshdr->sh_size / rcshdr->sh_entsize; ++cnt) in is_rel_dyn()
1108 if (shdr->sh_entsize != 0 in is_rel_dyn()
1110 / shdr->sh_entsize)) in is_rel_dyn()
1120 if (reldata != NULL && shdr->sh_entsize != 0) in is_rel_dyn()
1122 inner < shdr->sh_size / shdr->sh_entsize; in is_rel_dyn()
1162 if (shdr->sh_entsize != 0 in is_rel_dyn()
1163 && dyn->d_un.d_val > shdr->sh_size / shdr->sh_entsize) in is_rel_dyn()
1173 if (reldata != NULL && shdr->sh_entsize != 0) in is_rel_dyn()
1175 inner < shdr->sh_size / shdr->sh_entsize; in is_rel_dyn()
1271 size_t sh_entsize = gelf_fsize (ebl->elf, reltype, 1, EV_CURRENT); in check_reloc_shdr() local
1272 if (shdr->sh_entsize != sh_entsize) in check_reloc_shdr()
1307 && dyndata != NULL && dynshdr->sh_entsize != 0) in check_reloc_shdr()
1308 for (size_t j = 0; j < dynshdr->sh_size / dynshdr->sh_entsize; ++j) in check_reloc_shdr()
1495 size_t sh_entsize = gelf_fsize (ebl->elf, ELF_T_RELA, 1, EV_CURRENT); in check_rela() local
1496 for (size_t cnt = 0; cnt < shdr->sh_size / sh_entsize; ++cnt) in check_rela()
1546 size_t sh_entsize = gelf_fsize (ebl->elf, ELF_T_REL, 1, EV_CURRENT); in check_rel() local
1547 for (size_t cnt = 0; cnt < shdr->sh_size / sh_entsize; ++cnt) in check_rel()
1653 size_t sh_entsize = gelf_fsize (ebl->elf, ELF_T_DYN, 1, EV_CURRENT); in check_dynamic() local
1654 if (shdr->sh_entsize != sh_entsize) in check_dynamic()
1664 for (cnt = 0; cnt < shdr->sh_size / sh_entsize; ++cnt) in check_dynamic()
1934 if (shdr->sh_entsize != sizeof (Elf32_Word)) in check_symtab_shndx()
1940 && shdr->sh_entsize != 0 in check_symtab_shndx()
1941 && symshdr->sh_entsize != 0 in check_symtab_shndx()
1942 && (shdr->sh_size / shdr->sh_entsize in check_symtab_shndx()
1943 < symshdr->sh_size / symshdr->sh_entsize)) in check_symtab_shndx()
2008 if (shdr->sh_size < (2 + nbucket + nchain) * shdr->sh_entsize) in check_sysv_hash()
2012 (long int) ((2 + nbucket + nchain) * shdr->sh_entsize)); in check_sysv_hash()
2016 if (symshdr != NULL && symshdr->sh_entsize != 0) in check_sysv_hash()
2018 size_t symsize = symshdr->sh_size / symshdr->sh_entsize; in check_sysv_hash()
2020 if (nchain > symshdr->sh_size / symshdr->sh_entsize) in check_sysv_hash()
2059 if (shdr->sh_size < (2 + nbucket + nchain) * shdr->sh_entsize) in check_sysv_hash64()
2063 (long int) ((2 + nbucket + nchain) * shdr->sh_entsize)); in check_sysv_hash64()
2067 if (symshdr != NULL && symshdr->sh_entsize != 0) in check_sysv_hash64()
2069 size_t symsize = symshdr->sh_size / symshdr->sh_entsize; in check_sysv_hash64()
2071 if (nchain > symshdr->sh_size / symshdr->sh_entsize) in check_sysv_hash64()
2155 if (symshdr != NULL && symshdr->sh_entsize != 0) in check_gnu_hash()
2156 maxidx = MIN (maxidx, symshdr->sh_size / symshdr->sh_entsize); in check_gnu_hash()
2256 else if (symshdr != NULL && symshdr->sh_entsize != 0 in check_gnu_hash()
2257 && symidx > symshdr->sh_size / symshdr->sh_entsize) in check_gnu_hash()
2303 if (shdr->sh_entsize != (tag == SHT_GNU_HASH in check_hash()
2315 if (shdr->sh_size < (tag == SHT_GNU_HASH ? 4 : 2) * (shdr->sh_entsize ?: 4)) in check_hash()
2380 || sym_shdr == NULL || sym_shdr->sh_entsize == 0) in compare_hash_gnu_hash()
2396 uint32_t nentries = sym_shdr->sh_size / sym_shdr->sh_entsize; in compare_hash_gnu_hash()
2450 if (hash_shdr->sh_entsize == sizeof (Elf32_Word)) in compare_hash_gnu_hash()
2485 else if (hash_shdr->sh_entsize == sizeof (Elf64_Word)) in compare_hash_gnu_hash()
2641 && shdr->sh_entsize != elf32_fsize (ELF_T_WORD, 1, EV_CURRENT)) in check_group()
2809 if (data == NULL || shdr->sh_entsize == 0) in has_copy_reloc()
2813 for (int i = 0; (size_t) i < shdr->sh_size / shdr->sh_entsize; ++i) in has_copy_reloc()
2825 for (int i = 0; (size_t) i < shdr->sh_size / shdr->sh_entsize; ++i) in has_copy_reloc()
2923 if (shdr->sh_entsize != 0 && symshdr->sh_entsize != 0 in check_versym()
2924 && (shdr->sh_size / shdr->sh_entsize in check_versym()
2925 != symshdr->sh_size / symshdr->sh_entsize)) in check_versym()
2932 if (symdata == NULL || shdr->sh_entsize == 0) in check_versym()
2936 for (int cnt = 1; (size_t) cnt < shdr->sh_size / shdr->sh_entsize; ++cnt) in check_versym()
3024 && data != NULL && shdr->sh_entsize != 0) in unknown_dependency_p()
3025 for (size_t j = 0; j < shdr->sh_size / shdr->sh_entsize; ++j) in unknown_dependency_p()
3678 if (shdr->sh_entsize != 0) in check_sections()
3859 if (shdr->sh_entsize != 0 && shdr->sh_size % shdr->sh_entsize) in check_sections()
3948 if ((shdr->sh_flags & SHF_MERGE) != 0 && shdr->sh_entsize == 0) in check_sections()