apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pque...@apache.org
Subject svn commit: r594993 - in /apr/apr/branches/1.2.x: CHANGES network_io/unix/multicast.c
Date Wed, 14 Nov 2007 18:01:40 GMT
Author: pquerna
Date: Wed Nov 14 10:01:39 2007
New Revision: 594993

URL: http://svn.apache.org/viewvc?rev=594993&view=rev
Log:
Merge r493802 from trunk to 1.2:
* network_io/unix/multicast.c (find_if_index): Fix build if
APR_HAVE_IPV6 == 0 on platforms with getifaddrs().

PR: 39199



Modified:
    apr/apr/branches/1.2.x/CHANGES
    apr/apr/branches/1.2.x/network_io/unix/multicast.c

Modified: apr/apr/branches/1.2.x/CHANGES
URL: http://svn.apache.org/viewvc/apr/apr/branches/1.2.x/CHANGES?rev=594993&r1=594992&r2=594993&view=diff
==============================================================================
--- apr/apr/branches/1.2.x/CHANGES [utf-8] (original)
+++ apr/apr/branches/1.2.x/CHANGES [utf-8] Wed Nov 14 10:01:39 2007
@@ -1,6 +1,9 @@
                                                      -*- coding: utf-8 -*-
 Changes for APR 1.2.12
 
+  *) Fix --disable-ipv6 build on platforms with getifaddrs().
+     PR 39199.  [Joe Orton]
+
   *) Fix DSO-related crash on z/OS caused by incorrect memory
      allocation.  [David Jones <oscaremma gmail.com>]
 

Modified: apr/apr/branches/1.2.x/network_io/unix/multicast.c
URL: http://svn.apache.org/viewvc/apr/apr/branches/1.2.x/network_io/unix/multicast.c?rev=594993&r1=594992&r2=594993&view=diff
==============================================================================
--- apr/apr/branches/1.2.x/network_io/unix/multicast.c (original)
+++ apr/apr/branches/1.2.x/network_io/unix/multicast.c Wed Nov 14 10:01:39 2007
@@ -57,11 +57,13 @@
     }
 }
 
-#if APR_HAVE_IPV6
+/* This function is only interested in AF_INET6 sockets, so a noop
+ * "return 0" implementation for the !APR_HAVE_IPV6 build is
+ * sufficient. */
 static unsigned int find_if_index(const apr_sockaddr_t *iface)
 {
     unsigned int index = 0;
-#ifdef HAVE_GETIFADDRS
+#if defined(HAVE_GETIFADDRS) && APR_HAVE_IPV6 
     struct ifaddrs *ifp, *ifs;
 
     /**
@@ -92,6 +94,7 @@
     return index;
 }
 
+#if APR_HAVE_IPV6
 static void fill_mip_v6(struct ipv6_mreq *mip, const apr_sockaddr_t *mcast,
                         const apr_sockaddr_t *iface)
 {



Mime
View raw message