session.h: Support ifindex greater than 255
Change ifindex of struct session_t to int to support kernel environments
where ifindex can be over 255.
Change-Id: I03e42a237533424515f58fc30f9ac50282c11712
Signed-off-by: Jon Shallow <supjps-libcoap@jpshallow.com>
Signed-off-by: Olaf Bergmann <bergmann@tzi.org>
diff --git a/session.h b/session.h
index ef013d6..a2b58f4 100644
--- a/session.h
+++ b/session.h
@@ -39,7 +39,7 @@
unsigned short port;
int ifindex;
} session_t;
-#else /* WITH_CONTIKI */
+#else /* ! WITH_CONTIKI && ! WITH_RIOT_GNRC */
#include <sys/socket.h>
#include <netinet/in.h>
@@ -53,9 +53,9 @@
struct sockaddr_in sin;
struct sockaddr_in6 sin6;
} addr;
- uint8_t ifindex;
+ int ifindex;
} session_t;
-#endif /* WITH_CONTIKI */
+#endif /* ! WITH_CONTIKI && ! WITH_RIOT_GNRC */
/**
* Resets the given session_t object @p sess to its default