Check endianness the FreeBSD way.

This commit is contained in:
jb 2007-11-28 22:12:21 +00:00
parent ef879fff8b
commit 7d2b629940
2 changed files with 2 additions and 2 deletions

View File

@ -1918,7 +1918,7 @@ nvlist_common(nvlist_t *nvl, char *buf, size_t *buflen, int encoding,
int err = 0; int err = 0;
nvstream_t nvs; nvstream_t nvs;
int nvl_endian; int nvl_endian;
#ifdef _LITTLE_ENDIAN #if BYTE_ORDER == _LITTLE_ENDIAN
int host_endian = 1; int host_endian = 1;
#else #else
int host_endian = 0; int host_endian = 0;

View File

@ -1918,7 +1918,7 @@ nvlist_common(nvlist_t *nvl, char *buf, size_t *buflen, int encoding,
int err = 0; int err = 0;
nvstream_t nvs; nvstream_t nvs;
int nvl_endian; int nvl_endian;
#ifdef _LITTLE_ENDIAN #if BYTE_ORDER == _LITTLE_ENDIAN
int host_endian = 1; int host_endian = 1;
#else #else
int host_endian = 0; int host_endian = 0;