struct sockaddr *from, socklen_t *fromlen,
struct sockaddr *to, socklen_t *tolen)
{
-#if !defined(IP_PKTINFO) && !defined(IPV6_PKTINFO)
+#if (!defined(IP_PKTINFO) && !defined(IPV6_PKTINFO)) || !defined(CMSG_SPACE)
if (to && tolen)
*tolen = 0;
return recvfrom(s, buf, len, flags, from, fromlen);
const struct sockaddr *to, socklen_t tolen,
const struct sockaddr *from, socklen_t fromlen)
{
-#if !defined(IP_PKTINFO) && !defined(IPV6_PKTINFO)
+#if (!defined(IP_PKTINFO) && !defined(IPV6_PKTINFO)) || !defined(CMSG_SPACE)
return sendto(s, buf, len, flags, to, tolen);
#else
struct iovec iov;