diff options
author | Lennart Poettering <lennart@poettering.net> | 2024-11-12 23:17:41 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2024-11-12 23:45:15 +0100 |
commit | f2b4f1988184e0bcdb83900d1949cbfb98d61c90 (patch) | |
tree | 913710bf0be524e102a7bfaca860c3f81832d76b /src/boot | |
parent | pe: remove unnecessary log message about DT/HWID (diff) | |
download | systemd-f2b4f1988184e0bcdb83900d1949cbfb98d61c90.tar.xz systemd-f2b4f1988184e0bcdb83900d1949cbfb98d61c90.zip |
pe: use PE_SECTION_VECTOR_IS_SET() macro where appropriate
Diffstat (limited to 'src/boot')
-rw-r--r-- | src/boot/pe.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/boot/pe.c b/src/boot/pe.c index e4cb942426..69b42faff5 100644 --- a/src/boot/pe.c +++ b/src/boot/pe.c @@ -320,7 +320,7 @@ static void pe_locate_sections( /* device */ NULL, &hwids_section); - if (hwids_section.memory_offset != 0) { + if (PE_SECTION_VECTOR_IS_SET(&hwids_section)) { hwids = (const uint8_t *) SIZE_TO_PTR(validate_base) + hwids_section.memory_offset; EFI_STATUS err = chid_match(hwids, hwids_section.memory_size, &device); @@ -358,7 +358,7 @@ static uint32_t get_compatibility_entry_address(const DosFileHeader *dos, const PTR_TO_SIZE(dos), &vector); - if (vector.memory_size == 0) /* not found */ + if (!PE_SECTION_VECTOR_IS_SET(&vector)) /* not found */ return 0; typedef struct { |