2011-07-05 17:39:51 +00:00
|
|
|
--- a/lib/radiotap.c
|
|
|
|
+++ b/lib/radiotap.c
|
2011-07-05 17:07:40 +00:00
|
|
|
@@ -16,6 +16,17 @@
|
|
|
|
#include <click/radiotap_iter.h>
|
|
|
|
#include <click/platform.h>
|
|
|
|
|
|
|
|
+#if !defined(le32toh) || !defined(le16toh)
|
|
|
|
+# if BYTE_ORDER == LITTLE_ENDIAN
|
|
|
|
+# define le32toh(x) (x)
|
|
|
|
+# define le16toh(x) (x)
|
|
|
|
+# else
|
|
|
|
+# include <byteswap.h>
|
|
|
|
+# define le32toh(x) bswap_32(x)
|
|
|
|
+# define le16toh(x) bswap_16(x)
|
|
|
|
+# endif
|
|
|
|
+#endif
|
|
|
|
+
|
|
|
|
/* function prototypes and related defs are in radiotap_iter.h */
|
|
|
|
|
|
|
|
static const struct radiotap_align_size rtap_namespace_sizes[] = {
|