mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 18:18:12 +00:00
Everywhere: Replace ElfW(type)
macro usage with Elf_type
This works around a `clang-format-17` bug which caused certain usages to be misformatted and fail to compile. Fixes #8315
This commit is contained in:
parent
2151e6c8b4
commit
45d81dceed
20 changed files with 129 additions and 127 deletions
|
@ -55,7 +55,7 @@ Result<NonnullRefPtr<DynamicLoader>, DlErrorMessage> DynamicLoader::try_create(i
|
|||
|
||||
VERIFY(stat.st_size >= 0);
|
||||
auto size = static_cast<size_t>(stat.st_size);
|
||||
if (size < sizeof(ElfW(Ehdr)))
|
||||
if (size < sizeof(Elf_Ehdr))
|
||||
return DlErrorMessage { DeprecatedString::formatted("File {} has invalid ELF header", filepath) };
|
||||
|
||||
DeprecatedString file_mmap_name = DeprecatedString::formatted("ELF_DYN: {}", filepath);
|
||||
|
@ -132,7 +132,7 @@ bool DynamicLoader::validate()
|
|||
if (!image().is_valid())
|
||||
return false;
|
||||
|
||||
auto* elf_header = (ElfW(Ehdr)*)m_file_data;
|
||||
auto* elf_header = (Elf_Ehdr*)m_file_data;
|
||||
if (!validate_elf_header(*elf_header, m_file_size))
|
||||
return false;
|
||||
auto result_or_error = validate_program_headers(*elf_header, m_file_size, { m_file_data, m_file_size });
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue