Commits

Thomas Petazzoni  committed db3682d

Add missing INET6 conditional

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Steve Dickson <steved@redhat.com>

  • Participants
  • Parent commits 8cbabed

Comments (0)

Files changed (2)

File src/rpc_generic.c

 	    si.si_af == AF_INET6) {
 		int val = 1;
 
+#ifdef INET6
 		setsockopt(fd, SOL_IPV6, IPV6_V6ONLY, &val, sizeof(val));
+#endif
 	}
 	return fd;
 }

File src/svc_dg.c

 	case AF_INET:
 		(void) setsockopt(fd, SOL_IP, IP_PKTINFO, &val, sizeof(val));
 		break;
-
+#ifdef INET6
 	case AF_INET6:
 		(void) setsockopt(fd, SOL_IPV6, IPV6_RECVPKTINFO, &val, sizeof(val));
 		break;
+#endif
 	}
 }
 
 		}
 		break;
 
+#ifdef INET6
 	case AF_INET6:
 		if (cmsg->cmsg_level != SOL_IPV6
 		 || cmsg->cmsg_type != IPV6_PKTINFO
 			pkti->ipi6_ifindex = 0;
 		}
 		break;
+#endif
 
 	default:
 		return 0;