aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/include/linux_compat.h11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/include/linux_compat.h b/src/include/linux_compat.h
index 38601f180..1410cda67 100644
--- a/src/include/linux_compat.h
+++ b/src/include/linux_compat.h
@@ -91,7 +91,6 @@ typedef uint u_int32_t;
#define _WS2TCPIP_H_ /* Avoid compilation problems */
#define HAVE_SIN6_LEN
-
/* IPv6 address */
/* Already defined in WS2tcpip.h */
struct ndpi_win_in6_addr
@@ -129,6 +128,7 @@ struct ndpi_ip6_ext
u_int8_t ip6e_len; /* length in units of 8 octets. */
};
+#define s6_addr __u6_addr.__u6_addr8
#define s6_addr16 __u6_addr.__u6_addr16
#define s6_addr32 __u6_addr.__u6_addr32
#else
@@ -137,8 +137,6 @@ struct ndpi_ip6_ext
#endif
#endif
-
-
struct ndpi_in6_addr {
union {
u_int8_t __u6_addr8[16];
@@ -147,6 +145,13 @@ struct ndpi_in6_addr {
} __u6_addr; /* 128-bit IP6 address */
};
+#undef s6_addr
+#undef s6_addr16
+#undef s6_addr32
+#define s6_addr __u6_addr.__u6_addr8
+#define s6_addr16 __u6_addr.__u6_addr16
+#define s6_addr32 __u6_addr.__u6_addr32
+
struct ndpi_ip6_hdr {
union {
struct ndpi_ip6_hdrctl {