Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1bb929be authored by Bowgo Tsai's avatar Bowgo Tsai Committed by android-build-merger
Browse files

Merge "<android-base/endian.h>: fix interoperability issue"

am: ea378530

Change-Id: I5d9b418c6f4d39346eaaab7fb0eae8d5667ac5a5
parents a8ed306b ea378530
Loading
Loading
Loading
Loading
+3 −1
Original line number Original line Diff line number Diff line
@@ -51,8 +51,10 @@
/* macOS has some of the basics. */
/* macOS has some of the basics. */
#include <sys/_endian.h>
#include <sys/_endian.h>
#else
#else
/* Windows has even less. */
/* Windows has some of the basics as well. */
#include <sys/param.h>
#include <sys/param.h>
#include <winsock2.h>
/* winsock2.h *must* be included before the following four macros. */
#define htons(x) __builtin_bswap16(x)
#define htons(x) __builtin_bswap16(x)
#define htonl(x) __builtin_bswap32(x)
#define htonl(x) __builtin_bswap32(x)
#define ntohs(x) __builtin_bswap16(x)
#define ntohs(x) __builtin_bswap16(x)