net/: Fix a sixlowpan typo bug recently introduced; Rename g_ipv6_allzeroaddre with the more meaning g_ipv6_unspecaddr since the all-zero address is the IPv6 unspecified address (sometime IN6_ADDR_ANY). Remove more inline tests for IPv6 multicast with tcommint net_is_addr_mcast() macro. Update some comments.

This commit is contained in:
Gregory Nutt
2018-06-23 12:53:27 -06:00
parent 5bb216fb90
commit a0e169ad7b
19 changed files with 85 additions and 63 deletions
+4 -2
View File
@@ -304,9 +304,11 @@ FAR struct net_driver_s *netdev_findby_ipv6addr(const net_ipv6addr_t lipaddr,
if (net_is_addr_mcast(ripaddr))
{
/* Yes.. Check the local, bound address. Is it INADDR_ANY? */
/* Yes.. Check the local, bound address. Is it the IPv6 unspecified
* address?
*/
if (net_ipv6addr_cmp(lipaddr, g_ipv6_allzeroaddr))
if (net_ipv6addr_cmp(lipaddr, g_ipv6_unspecaddr))
{
/* Yes.. In this case, I think we are supposed to send the
* broadcast packet out ALL locally available networks. I am not
+1 -1
View File
@@ -183,7 +183,7 @@ static int ifconf_ipv6_callback(FAR struct net_driver_s *dev, FAR void *arg)
* state.
*/
if (!net_ipv6addr_cmp(dev->d_ipv6addr, g_ipv6_allzeroaddr) &&
if (!net_ipv6addr_cmp(dev->d_ipv6addr, g_ipv6_unspecaddr) &&
(dev->d_flags & IFF_UP) != 0)
{
/* Check if we would exceed the buffer space provided by the caller.