mirror of
https://github.com/apache/nuttx.git
synced 2026-05-28 11:56:10 +08:00
net/sixlowpan: Fix a constant value used in IPv6 address decompression. The 0x0200 value used in the address modification should be in network order.
This commit is contained in:
@@ -3,7 +3,7 @@
|
|||||||
* 6lowpan HC06 implementation (draft-ietf-6lowpan-hc-06, updated to RFC
|
* 6lowpan HC06 implementation (draft-ietf-6lowpan-hc-06, updated to RFC
|
||||||
* 6282)
|
* 6282)
|
||||||
*
|
*
|
||||||
* Copyright (C) 2017, Gregory Nutt, all rights reserved
|
* Copyright (C) 2017-2018 Gregory Nutt, all rights reserved
|
||||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||||
*
|
*
|
||||||
* Derives from Contiki:
|
* Derives from Contiki:
|
||||||
@@ -506,7 +506,7 @@ static void uncompress_addr(FAR const struct netdev_varaddr_s *addr,
|
|||||||
|
|
||||||
if (fullmac)
|
if (fullmac)
|
||||||
{
|
{
|
||||||
ipaddr[7] ^= 0x0200;
|
ipaddr[7] ^= HTONS(0x0200);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* If we took the data from packet, then update the packet pointer */
|
/* If we took the data from packet, then update the packet pointer */
|
||||||
|
|||||||
Reference in New Issue
Block a user