summaryrefslogtreecommitdiffstats
path: root/src/shared/pe-binary.c
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-12 03:50:42 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-12 03:50:42 +0000
commit78e9bb837c258ac0ec7712b3d612cc2f407e731e (patch)
treef515d16b6efd858a9aeb5b0ef5d6f90bf288283d /src/shared/pe-binary.c
parentAdding debian version 255.5-1. (diff)
downloadsystemd-78e9bb837c258ac0ec7712b3d612cc2f407e731e.tar.xz
systemd-78e9bb837c258ac0ec7712b3d612cc2f407e731e.zip
Merging upstream version 256.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/shared/pe-binary.c')
-rw-r--r--src/shared/pe-binary.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/shared/pe-binary.c b/src/shared/pe-binary.c
index 4c05323..997e0e4 100644
--- a/src/shared/pe-binary.c
+++ b/src/shared/pe-binary.c
@@ -234,8 +234,9 @@ bool pe_is_uki(const PeHeader *pe_header, const IMAGE_SECTION_HEADER *sections)
if (le16toh(pe_header->optional.Subsystem) != IMAGE_SUBSYSTEM_EFI_APPLICATION)
return false;
+ /* Note that the UKI spec only requires .linux, but we are stricter here, and require .osrel too,
+ * since for sd-boot it just doesn't make sense to not have that. */
return
pe_header_find_section(pe_header, sections, ".osrel") &&
- pe_header_find_section(pe_header, sections, ".linux") &&
- pe_header_find_section(pe_header, sections, ".initrd");
+ pe_header_find_section(pe_header, sections, ".linux");
}