Browse Source

Fix ipv6 compilation on FreeBSD and probably other systems with Kame-derived
IPv6 stacks: IN6_IS_ADDR_MULTICAST() doesn't automagically casts its argument
to struct in6_addr * there.

Maxim Sobolev 21 years ago
parent
commit
ca85b625d4
1 changed files with 1 additions and 1 deletions
  1. 1 1
      ip_addr.c

+ 1 - 1
ip_addr.c

@@ -176,7 +176,7 @@ int is_mcast(struct ip_addr* ip)
 		return IN_MULTICAST(htonl(ip->u.addr32[0]));
 #ifdef USE_IPV6
 	} else if (ip->af==AF_INET6){
-		return IN6_IS_ADDR_MULTICAST(ip->u.addr);
+		return IN6_IS_ADDR_MULTICAST((struct in6_addr *)ip->u.addr);
 #endif /* USE_IPV6 */
 	} else {
 		LOG(L_ERR, "ERROR: is_mcast: Unsupported protocol family\n");