From 5f8c7f91de316b905a1ffa5745d25a48062c7d4f Mon Sep 17 00:00:00 2001 From: Petr Sumbera Date: Tue, 4 Nov 2025 15:37:30 +0100 Subject: [PATCH] Fix for big endian platforms. https://bugzilla.nasm.us/show_bug.cgi?id=3392745 --- output/outelf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/output/outelf.c b/output/outelf.c index 7288dda1..e03c1623 100644 --- a/output/outelf.c +++ b/output/outelf.c @@ -1883,7 +1883,7 @@ static void elf_write(void) ehdr.com.e_ident[EI_ABIVERSION] = elf_abiver; ehdr.com.e_type = htole16(ET_REL); ehdr.com.e_machine = htole16(efmt->e_machine); - ehdr.com.e_version = htole16(EV_CURRENT); + ehdr.com.e_version = htole32(EV_CURRENT); if (!efmt->elf64) { ehdr.ehdr32.e_shoff = htole32(sizeof ehdr);