From 040bb0955b9061b52400e6cd3507a075195b8192 Mon Sep 17 00:00:00 2001 From: Christos Tsantilas Date: Wed, 29 Jun 2011 22:58:09 +0300 Subject: [PATCH] Ip::Address::IsAnyAddr did not return true in the case the ip address is an ipv4 anyaddr --- src/ip/Address.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ip/Address.cc b/src/ip/Address.cc index 420b968928..310b032110 100644 --- a/src/ip/Address.cc +++ b/src/ip/Address.cc @@ -185,7 +185,7 @@ Ip::Address::IsIPv6() const bool Ip::Address::IsAnyAddr() const { - return IN6_IS_ADDR_UNSPECIFIED( &m_SocketAddr.sin6_addr ); + return IN6_IS_ADDR_UNSPECIFIED( &m_SocketAddr.sin6_addr ) || IN6_ARE_ADDR_EQUAL( &m_SocketAddr.sin6_addr, &v4_anyaddr); } /// NOTE: Does NOT clear the Port stored. Ony the Address and Type. -- 2.47.2