Re: [PATCH] tests/qtest/libqos: Fix UBSan misalignment finding

2025-04-29 Thread Laurent Vivier
On 28/04/2025 23:20, Nabih Estefan wrote: Running with `--enable-ubsan` leads to a qtest failure: ``` ../tests/qtest/libqos/igb.c:106:5: runtime error: load of misaligned address 0x562040be8e33 for type 'uint32_t', which requires 4 byte alignment ``` Instead of straight casting the uint8_t array

[PATCH] tests/qtest/libqos: Fix UBSan misalignment finding

2025-04-28 Thread Nabih Estefan
Running with `--enable-ubsan` leads to a qtest failure: ``` ../tests/qtest/libqos/igb.c:106:5: runtime error: load of misaligned address 0x562040be8e33 for type 'uint32_t', which requires 4 byte alignment ``` Instead of straight casting the uint8_t array, we use memcpy to assure alignment is corre