mirror of
https://gitlab.freedesktop.org/xorg/xserver.git
synced 2026-01-06 17:50:12 +01:00
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>
(cherry picked from commit 1af15aaf27)
This commit is contained in:
parent
5497f56b87
commit
40f35e4488
1 changed files with 2 additions and 0 deletions
|
|
@ -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…
Add table
Reference in a new issue