dix: Fix image byte order on big endian hardware
Make sure X_BIG_ENDIAN/X_LITTLE_ENDIAN are defined before actually using them. Otherwise, image byte order could be wrong on big endian hardware even though endianess detection is correct. Reported-by: Tim Waugh <twaugh@redhat.com> Signed-off-by: Olivier Fourdan <ofourdan@redhat.com> Reviewed-by: Adam Jackson <ajax@redhat.com>
This commit is contained in:
parent
28159eff6b
commit
1af15aaf27
|
@ -52,6 +52,8 @@ SOFTWARE.
|
|||
#error xserver code must include dix-config.h before any other headers
|
||||
#endif
|
||||
|
||||
#include <X11/Xarch.h> /* for X_LITTLE_ENDIAN/X_BIG_ENDIAN */
|
||||
|
||||
#if X_BYTE_ORDER == X_LITTLE_ENDIAN
|
||||
#define IMAGE_BYTE_ORDER LSBFirst
|
||||
#define BITMAP_BIT_ORDER LSBFirst
|
||||
|
|
Loading…
Reference in New Issue