On both IBM AIX and Gentoo Linux, the struct `ip_mreq` does not define
the field `imr_address`, plus the compiler throws an error in the
assignment of `sa->s_addr`. With `ip_mreqn` present, the fallback path
for `ip_mreq` is not used and everything works. But AIX does not know
that struct and fails to compile.
};
#else
struct ip_mreq mreq = {
- .imr_address.s_addr = INADDR_ANY, .imr_multiaddr.s_addr = sa->s_addr,
+ .imr_multiaddr.s_addr = sa->sin_addr.s_addr,
};
#endif
status = setsockopt(srv->conn, IPPROTO_IP, IP_ADD_MEMBERSHIP, &mreq,