From 576e93a583d65f624b1922bc75f053621ca67120 Mon Sep 17 00:00:00 2001 From: jorton Date: Mon, 10 Jan 2005 16:36:56 +0000 Subject: * network_io/unix/multicast.c: Use #ifdef not #if for HAVE_GETIFADDRS. (find_if_index): Fix unused variables warnings if HAVE_GETIFADDRS is undefined. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@124813 13f79535-47bb-0310-9956-ffa450edef68 --- network_io/unix/multicast.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'network_io/unix/multicast.c') diff --git a/network_io/unix/multicast.c b/network_io/unix/multicast.c index ba92bb9f4..695500f19 100644 --- a/network_io/unix/multicast.c +++ b/network_io/unix/multicast.c @@ -19,7 +19,7 @@ #include "apr_portable.h" #include "apr_arch_inherit.h" -#if HAVE_GETIFADDRS +#ifdef HAVE_GETIFADDRS #include #include #endif @@ -59,6 +59,7 @@ static void fill_mip_v4(struct ip_mreq *mip, apr_sockaddr_t *mcast, static unsigned int find_if_index(const apr_sockaddr_t *iface) { unsigned int index = 0; +#ifdef HAVE_GETIFADDRS struct ifaddrs *ifp, *ifs; /** @@ -69,7 +70,6 @@ static unsigned int find_if_index(const apr_sockaddr_t *iface) * getifaddrs. The license is acceptable, but, It is a fairly large * chunk of code. */ -#if HAVE_GETIFADDRS if (getifaddrs(&ifs) != 0) { return 0; } -- cgit v1.2.1