getifaddrs: Fix building on systems without IFF_SLAVE.

This commit is contained in:
Justin Maggard 2014-02-03 11:57:34 -08:00
parent 582dd80f3b
commit 67fd1fe45a

View File

@ -44,18 +44,21 @@
#include "config.h"
#if HAVE_GETIFADDRS
#include <ifaddrs.h>
#ifdef __linux__
#ifndef AF_LINK
#define AF_LINK AF_INET
#endif
#else
#include <net/if_dl.h>
#endif
# include <ifaddrs.h>
# ifdef __linux__
# ifndef AF_LINK
# define AF_LINK AF_INET
# endif
# else
# include <net/if_dl.h>
# endif
# ifndef IFF_SLAVE
# define IFF_SLAVE 0
# endif
#endif
#ifdef HAVE_NETLINK
#include <linux/rtnetlink.h>
#include <linux/netlink.h>
# include <linux/rtnetlink.h>
# include <linux/netlink.h>
#endif
#include "upnpglobalvars.h"
#include "getifaddr.h"