pkgsrc/net/vino/patches/patch-ac
drochner 493c13c99e update to 2.28.1
this switches to the Gnome-2.28 branch
2010-01-21 18:20:43 +00:00

19 lines
653 B
Text

$NetBSD: patch-ac,v 1.1 2010/01/21 18:20:43 drochner Exp $
--- server/libvncserver/sockets.c.orig 2009-05-12 11:39:33.000000000 +0000
+++ server/libvncserver/sockets.c
@@ -671,6 +671,14 @@ NewSocketListenTCP(struct sockaddr *addr
if ((sock = socket(addr->sa_family, SOCK_STREAM, 0)) < 0)
return -1;
+#if defined(__NetBSD__) && defined(ENABLE_IPV6)
+ if (addr->sa_family == AF_INET6) {
+ /* NetBSD defaults to V6ONLY */
+ int no = 0;
+ setsockopt(sock, IPPROTO_IPV6, IPV6_V6ONLY, &no, sizeof(no));
+ }
+#endif
+
if (setsockopt(sock, SOL_SOCKET, SO_REUSEADDR, (char *)&one, sizeof(one)) < 0) {
close(sock);
return -1;