Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
asf: fix GUID reading on big endian platforms
Setting the initial parts (data1_, data2_, data3_) from the bytes directly using memcpy() means that they will be interpreted depending on the platform endianness. For example, the initial 4 bytes of the ASF header are 0x30, 0x26, 0xB2, 0x75, which will be read as 0x3026B275 on big endian platforms, never matching the actual GUID (0x75B22630), which is always specified in little endian format. Hence, when reading a GUID from data, make sure to turn the GUID parts to little endian. This fixes the reading of ASF files on big endian platforms. Fixes commit bed8d3d
- Loading branch information