mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 16:07:47 +00:00
Kernel: Consolidate finding the ELF stack size with validation
Previously, we started parsing the ELF file again in a completely different place, and without the partial mapping that we do while validating. Instead of doing manual parsing in two places, just capture the requested stack size right after we validated it.
This commit is contained in:
parent
398f7ae988
commit
9d6372ff07
5 changed files with 29 additions and 49 deletions
|
@ -128,7 +128,7 @@ bool Image::parse()
|
|||
return false;
|
||||
}
|
||||
|
||||
auto result_or_error = validate_program_headers(header(), m_size, { m_buffer, m_size }, nullptr, m_verbose_logging);
|
||||
auto result_or_error = validate_program_headers(header(), m_size, { m_buffer, m_size }, nullptr, nullptr, m_verbose_logging);
|
||||
if (result_or_error.is_error()) {
|
||||
if (m_verbose_logging)
|
||||
dbgln("ELF::Image::parse(): Failed validating ELF Program Headers");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue