From a9588b5c9d0577c0e13f396bd768f32126a679a8 Mon Sep 17 00:00:00 2001 From: Dagobert Michelsen Date: Wed, 4 Apr 2018 14:34:15 +0200 Subject: [PATCH] Fix conditional on byteorder to work on Solaris --- src/stdendian.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/stdendian.h b/src/stdendian.h index 4d32b156..f84a03dc 100644 --- a/src/stdendian.h +++ b/src/stdendian.h @@ -211,7 +211,7 @@ /* Host swap macros */ #ifndef __HOSTSWAP_DEFINED -#if __BYTE_ORDER == __LITTLE_ENDIAN +#if _BYTE_ORDER == _LITTLE_ENDIAN #define htobe16(x) bswap16((x)) #define htole16(x) ((uint16_t)(x)) #define be16toh(x) bswap16((x)) @@ -226,7 +226,7 @@ #define htole64(x) ((uint64_t)(x)) #define be64toh(x) bswap64((x)) #define le64toh(x) ((uint64_t)(x)) -#elif __BYTE_ORDER == __BIG_ENDIAN +#elif _BYTE_ORDER == _BIG_ENDIAN #define htobe16(x) ((uint16_t)(x)) #define htole16(x) bswap16((x)) #define be16toh(x) ((uint16_t)(x)) -- 2.11.0