From 2b5ed83fec55f5d96338fe3ae5e394bed1a407f4 Mon Sep 17 00:00:00 2001 From: Seonah Moon Date: Thu, 21 Jun 2018 15:44:41 +0900 Subject: Imported Upstream version 2.79 Change-Id: I9a2f4c945e0481ab803bdf0c85921433f33a9256 Signed-off-by: Seonah Moon --- src/bpf.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'src/bpf.c') diff --git a/src/bpf.c b/src/bpf.c index a066641..49a11bf 100644 --- a/src/bpf.c +++ b/src/bpf.c @@ -1,4 +1,4 @@ -/* dnsmasq is Copyright (c) 2000-2015 Simon Kelley +/* dnsmasq is Copyright (c) 2000-2018 Simon Kelley This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -20,7 +20,9 @@ #include #include +#if defined(HAVE_BSD_NETWORK) && !defined(__APPLE__) #include +#endif #include #include #include @@ -103,7 +105,7 @@ int arp_enumerate(void *parm, int (*callback)()) int iface_enumerate(int family, void *parm, int (*callback)()) { struct ifaddrs *head, *addrs; - int errsav, fd = -1, ret = 0; + int errsave, fd = -1, ret = 0; if (family == AF_UNSPEC) #if defined(HAVE_BSD_NETWORK) && !defined(__APPLE__) @@ -235,11 +237,11 @@ int iface_enumerate(int family, void *parm, int (*callback)()) ret = 1; err: - errsav = errno; + errsave = errno; freeifaddrs(head); if (fd != -1) close(fd); - errno = errsav; + errno = errsave; return ret; } -- cgit v1.2.3