]> git.pld-linux.org Git - packages/ntp.git/blobdiff - ntp-ipv6.patch
- without_avahi bcond and BR: avahi-compat-libdns_sd-devel
[packages/ntp.git] / ntp-ipv6.patch
index c4f33463b897245588ec09ef5d21006ed2c55f58..674a6a78905e4d1d8b8b45643f81f7c68ee8190d 100644 (file)
@@ -1,21 +1,19 @@
-diff -urN ntp-4.2.0.org/ntpdate/ntpdate.c ntp-4.2.0/ntpdate/ntpdate.c
---- ntp-4.2.0.org/ntpdate/ntpdate.c    2004-05-17 00:41:52.720460048 +0200
-+++ ntp-4.2.0/ntpdate/ntpdate.c        2004-05-17 01:33:48.375808440 +0200
-@@ -1756,12 +1756,14 @@
-          }
+diff -durN -x '*.orig' ntp-4.2.6p1.orig/ntpdate/ntpdate.c ntp-4.2.6p1/ntpdate/ntpdate.c
+--- ntp-4.2.6p1.orig/ntpdate/ntpdate.c 2010-05-24 19:28:54.000000000 +0200
++++ ntp-4.2.6p1/ntpdate/ntpdate.c      2010-05-24 19:30:19.000000000 +0200
+@@ -1729,11 +1729,13 @@
+               }
  #ifdef IPV6_V6ONLY
-          /* Restricts AF_INET6 socket to IPv6 communications (see RFC 2553bis-03) */
--         if (res->ai_family == AF_INET6)
--              if (setsockopt(fd[nbsock], IPPROTO_IPV6, IPV6_V6ONLY, (void*) &optval, sizeof(optval)) < 0) {
-+         if (res->ai_family == AF_INET6) {
-+              int i = setsockopt(fd[nbsock], IPPROTO_IPV6, IPV6_V6ONLY, (void*) &optval, sizeof(optval));
-+              if (i < 0 && errno != ENOPROTOOPT) {
-                          netsyslog(LOG_ERR, "setsockopt() IPV6_V6ONLY failed: %m");
-                          exit(1);
-                          /*NOTREACHED*/
+               /* Restricts AF_INET6 socket to IPv6 communications (see RFC 2553bis-03) */
+-              if (res->ai_family == AF_INET6)
+-                      if (setsockopt(fd[nbsock], IPPROTO_IPV6, IPV6_V6ONLY, (void*) &optval, sizeof(optval)) < 0) {
++              if (res->ai_family == AF_INET6) {
++                      int i = setsockopt(fd[nbsock], IPPROTO_IPV6, IPV6_V6ONLY, (void*) &optval, sizeof(optval));
++                      if ( i < 0 && errno != ENOPROTOOPT ) {
+                                  msyslog(LOG_ERR, "setsockopt() IPV6_V6ONLY failed: %m");
+                                       exit(1);
+                                       /*NOTREACHED*/
++                      }
                }
-+         }
  #endif
  
-          /* Remember the socket family in fd_family structure */
-
This page took 0.030535 seconds and 4 git commands to generate.