mirror of
https://github.com/apache/nuttx.git
synced 2025-12-12 13:55:18 +08:00
sixlowpan: improve tcp support.
Update the handling of tcp packets over sixlowpan. `tcp_ipv6_input()` can update the dev->d_iob. Assigning ipv6 to IPv6BUF makes sure that the correct buffer is used. Signed-off-by: Laczen JMS <laczenjms@gmail.com>
This commit is contained in:
committed by
Alan C. Assis
parent
9f85eaf3cb
commit
34aa17b7a0
@@ -463,6 +463,12 @@ static int ipv6_in(FAR struct net_driver_s *dev)
|
||||
if ((dev->d_len > 0 && dev->d_lltype == NET_LL_IEEE802154) ||
|
||||
(dev->d_len > 0 && dev->d_lltype == NET_LL_PKTRADIO))
|
||||
{
|
||||
/* tcp_ipv6_input() can update dev->d_iob. Update ipv6 to ensure
|
||||
* using the correct data.
|
||||
*/
|
||||
|
||||
ipv6 = IPv6BUF;
|
||||
|
||||
/* Let 6LoWPAN handle the TCP output */
|
||||
|
||||
sixlowpan_tcp_send(dev, dev, ipv6);
|
||||
|
||||
Reference in New Issue
Block a user