Use better endianness check (by @heckflosse)

This commit is contained in:
Flössie
2019-11-20 14:58:46 +01:00
parent 5e393f2052
commit f42efdb2e0

View File

@@ -625,11 +625,11 @@ libraw_inline void _BitScanReverse(DWORD *Index, unsigned long Mask)
}
uint32_t _byteswap_ulong(uint32_t x)
{
#if BYTE_ORDER == BIG_ENDIAN
#if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
return x;
#else
#else
return __builtin_bswap32(x);
#endif
#endif
}
#endif