diff --git a/net/udp/udp_finddev.c b/net/udp/udp_finddev.c index 8e77140b833..2139bc1ca94 100644 --- a/net/udp/udp_finddev.c +++ b/net/udp/udp_finddev.c @@ -195,14 +195,14 @@ FAR struct net_driver_s *udp_find_raddr_device(FAR struct udp_conn_s *conn) * using the locally bound address (assuming that there is one). * * The general form of all well-known, reserved IPv6 multicast - * addresses is: ff0x::xx/16 (which does not include all possible - * multicast addresses). + * addresses is: ff0x::xx/16 (which includes most, but not all + * possible multicast addresses). */ - if ((conn->u.ipv6.laddr[0] & HTONS(0xfff0)) == HTONS(0xff00) && - conn->u.ipv6.laddr[1] == 0 && conn->u.ipv6.laddr[2] == 0 && - conn->u.ipv6.laddr[3] == 0 && conn->u.ipv6.laddr[4] == 0 && - conn->u.ipv6.laddr[5] == 0 && conn->u.ipv6.laddr[6] == 0) + if ((conn->u.ipv6.raddr[0] & HTONS(0xfff0)) == HTONS(0xff00) && + conn->u.ipv6.raddr[1] == 0 && conn->u.ipv6.raddr[2] == 0 && + conn->u.ipv6.raddr[3] == 0 && conn->u.ipv6.raddr[4] == 0 && + conn->u.ipv6.raddr[5] == 0 && conn->u.ipv6.raddr[6] == 0) { /* Make sure that the socket is bound to some non-zero, local * address. Zero is used as an indication that the laddr is