Re: [PATCH 02/10] linux-user: Fix parse_elf_properties GNU0_MAGIC check

2024-10-07 Thread Philippe Mathieu-Daudé
On 5/10/24 20:33, Richard Henderson wrote: Comparing a string of 4 bytes only works in little-endian. Adjust bulk bswap to only apply to the note payload. Perform swapping of the note header manually; the magic is defined so that it does not need a runtime swap. Fixes: 83f990eb5adb ("linux-user

[PATCH 02/10] linux-user: Fix parse_elf_properties GNU0_MAGIC check

2024-10-05 Thread Richard Henderson
Comparing a string of 4 bytes only works in little-endian. Adjust bulk bswap to only apply to the note payload. Perform swapping of the note header manually; the magic is defined so that it does not need a runtime swap. Fixes: 83f990eb5adb ("linux-user/elfload: Parse NT_GNU_PROPERTY_TYPE_0 notes"