1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-28 19:57:36 +00:00

LibELF: Return false instead of assert on unrecognized program header

This commit is contained in:
Andrew Kaster 2020-04-11 11:20:16 -06:00 committed by Andreas Kling
parent c199b0e1aa
commit f809231718

View file

@ -407,9 +407,8 @@ bool ELFImage::validate_program_headers(const Elf32_Ehdr& elf_header, size_t fil
break;
default:
// Not handling other program header types in other code so... let's not surprise them
dbgprintf("Found program header (%d) of unrecognized type %d!\n", header_index, program_header.p_type);
ASSERT_NOT_REACHED();
break;
dbgprintf("Found program header (%d) of unrecognized type %x!\n", header_index, program_header.p_type);
return false;
}
}
return true;