summaryrefslogtreecommitdiff
path: root/nuttx/net/tcp
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2015-01-15 13:08:28 -0600
committerGregory Nutt <gnutt@nuttx.org>2015-01-15 13:08:28 -0600
commitfe80c662f25081c8d2c9df8797af2dc89ead2f64 (patch)
tree88be6b6663fa39e646698f47bb1d07e800cce60e /nuttx/net/tcp
parentc16ad40ac4e49dce5846763d2c31f571c978e355 (diff)
downloadpx4-nuttx-fe80c662f25081c8d2c9df8797af2dc89ead2f64.tar.gz
px4-nuttx-fe80c662f25081c8d2c9df8797af2dc89ead2f64.tar.bz2
px4-nuttx-fe80c662f25081c8d2c9df8797af2dc89ead2f64.zip
Networking: More IPv6 detanglement
Diffstat (limited to 'nuttx/net/tcp')
-rw-r--r--nuttx/net/tcp/tcp_send_buffered.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/nuttx/net/tcp/tcp_send_buffered.c b/nuttx/net/tcp/tcp_send_buffered.c
index c50b81040..ed0632ccd 100644
--- a/nuttx/net/tcp/tcp_send_buffered.c
+++ b/nuttx/net/tcp/tcp_send_buffered.c
@@ -79,7 +79,11 @@
* Pre-processor Definitions
****************************************************************************/
-#define TCPBUF ((struct tcp_iphdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
+#if defined(CONFIG_NET_IPv4)
+# define TCPBUF ((struct tcp_iphdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
+#elif defined(CONFIG_NET_IPv6)
+# define TCPBUF ((struct tcp_ipv6hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
+#endif
/* Debug */