summaryrefslogtreecommitdiffstats
path: root/rfb/rfbproto.h
diff options
context:
space:
mode:
authorStefan Weil <sw@weilnetz.de>2015-10-10 12:12:38 +0200
committerStefan Weil <sw@weilnetz.de>2015-10-10 12:29:28 +0200
commitb71cc64e5865bd79bd446a0ef49694f415d8921f (patch)
treec6d3f1dbc546e8316382490e789e6451fd169e8f /rfb/rfbproto.h
parent97f442ef2aa65ade6bea11e90054c57b90abbaca (diff)
downloadlibtdevnc-b71cc64e5865bd79bd446a0ef49694f415d8921f.tar.gz
libtdevnc-b71cc64e5865bd79bd446a0ef49694f415d8921f.zip
Fix endianness detection
Commit 97f442ef2aa65ade6bea11e90054c57b90abbaca tried to improve the endianness detection, but introduced a typo and problems for Windows builds (no endian.h, different definition of LIBVNCSERVER_WORDS_BIGENDIAN). Fix both issues. Signed-off-by: Stefan Weil <sw@weilnetz.de>
Diffstat (limited to 'rfb/rfbproto.h')
-rw-r--r--rfb/rfbproto.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/rfb/rfbproto.h b/rfb/rfbproto.h
index 354f1aa..6921d4a 100644
--- a/rfb/rfbproto.h
+++ b/rfb/rfbproto.h
@@ -80,11 +80,12 @@
#endif
#endif
+#if !defined(_WIN32)
# include <endian.h>
# if __BYTE_ORDER == __BIG_ENDIAN
-# define LIBVBNCSERVER_WORDS_BIGENDIAN 1
+# define LIBVNCSERVER_WORDS_BIGENDIAN 1
# endif
-
+#endif /* !_WIN32 */
/* MS compilers don't have strncasecmp */
#ifdef _MSC_VER