Lines Matching defs:ehdr
332 Elf32_Ehdr *ehdr = addr;
335 switch (ehdr->e_ident[EI_DATA]) {
354 ehdr->e_ident[EI_DATA], fname);
358 if (memcmp(ELFMAG, ehdr->e_ident, SELFMAG) != 0 ||
359 (r2(&ehdr->e_type) != ET_EXEC && r2(&ehdr->e_type) != ET_DYN) ||
360 ehdr->e_ident[EI_VERSION] != EV_CURRENT) {
365 switch (r2(&ehdr->e_machine)) {
391 r2(&ehdr->e_machine), fname);
395 switch (ehdr->e_ident[EI_CLASS]) {
397 if (r2(&ehdr->e_ehsize) != sizeof(Elf32_Ehdr) ||
398 r2(&ehdr->e_shentsize) != sizeof(Elf32_Shdr)) {
403 rc = do_sort_32(ehdr, fname, custom_sort);
407 Elf64_Ehdr *const ghdr = (Elf64_Ehdr *)ehdr;
420 ehdr->e_ident[EI_CLASS], fname);