From b11b08ed641b8c677b529e108c2b28dc0183d34c Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Tue, 14 Jul 2009 14:28:04 -0700 Subject: [PATCH] Add a little paranoia here to ensure endianess is set correctly. --- include/sys/isa_defs.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/include/sys/isa_defs.h b/include/sys/isa_defs.h index 3b8fffe1e9..081133e5aa 100644 --- a/include/sys/isa_defs.h +++ b/include/sys/isa_defs.h @@ -73,7 +73,11 @@ extern "C" { #endif #if defined(_LITTLE_ENDIAN) && defined(_BIG_ENDIAN) -#error "Both _LITTLE_ENDIAN and __BIG_ENDIAN are defined" +#error "Both _LITTLE_ENDIAN and _BIG_ENDIAN are defined" +#endif + +#if !defined(_LITTLE_ENDIAN) && !defined(_BIG_ENDIAN) +#error "Neither _LITTLE_ENDIAN or _BIG_ENDIAN are defined" #endif #ifdef __cplusplus