aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBruce A. Mah <bmah@es.net>2014-09-15 15:09:50 -0700
committerBruce A. Mah <bmah@es.net>2014-09-15 15:09:50 -0700
commit1f29ffe70d789f9568a05e3625cbdcbc616407c6 (patch)
tree04801d0b7e5b17f10d8871e78bd69b00cb8d540b /src
parentdf9230810fda6fa8dbde6b549c015b456125c382 (diff)
downloadiperf3-1f29ffe70d789f9568a05e3625cbdcbc616407c6.tar.gz
Fix build on OpenBSD (tested on 5.4).
Breakage was introduced with commits for Issue #191.
Diffstat (limited to 'src')
-rw-r--r--src/portable_endian.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/portable_endian.h b/src/portable_endian.h
index 42d40be..ba56f64 100644
--- a/src/portable_endian.h
+++ b/src/portable_endian.h
@@ -42,6 +42,15 @@
# include <sys/endian.h>
+# define be16toh(x) betoh16(x)
+# define le16toh(x) letoh16(x)
+
+# define be32toh(x) betoh32(x)
+# define le32toh(x) letoh32(x)
+
+# define be64toh(x) betoh64(x)
+# define le64toh(x) letoh64(x)
+
#elif defined(__NetBSD__) || defined(__FreeBSD__) || defined(__DragonFly__)
# include <sys/endian.h>
@@ -112,4 +121,4 @@
#endif
-#endif \ No newline at end of file
+#endif