Module Name: src
Committed By: drochner
Date: Wed Sep 11 18:50:00 UTC 2013
Modified Files:
src/external/bsd/dhcpcd/dist: net.c
Log Message:
add a patch from upstream, fixing a regression which obstructed link
status detection on BSD virtual interfaces (observed with xennet)
To generate a diff of this commit:
cvs rdiff -u -r1.1.1.22 -r1.2 src/external/bsd/dhcpcd/dist/net.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/external/bsd/dhcpcd/dist/net.c
diff -u src/external/bsd/dhcpcd/dist/net.c:1.1.1.22 src/external/bsd/dhcpcd/dist/net.c:1.2
--- src/external/bsd/dhcpcd/dist/net.c:1.1.1.22 Fri Jun 21 19:33:07 2013
+++ src/external/bsd/dhcpcd/dist/net.c Wed Sep 11 18:50:00 2013
@@ -1,5 +1,5 @@
#include <sys/cdefs.h>
- __RCSID("$NetBSD: net.c,v 1.1.1.22 2013/06/21 19:33:07 roy Exp $");
+ __RCSID("$NetBSD: net.c,v 1.2 2013/09/11 18:50:00 drochner Exp $");
/*
* dhcpcd - DHCP client daemon
@@ -170,7 +170,7 @@ carrier_status(struct interface *iface)
#endif
if (ioctl(socket_afnet, SIOCGIFFLAGS, &ifr) == -1)
- return -1;
+ return LINK_UNKNOWN;
iface->flags = ifr.ifr_flags;
ret = LINK_UNKNOWN;
@@ -318,7 +318,7 @@ discover_interfaces(int argc, char * con
/* Bring the interface up if not already */
if (!(ifp->flags & IFF_UP)
#ifdef SIOCGIFMEDIA
- && carrier_status(ifp) != -1
+ && carrier_status(ifp) != LINK_UNKNOWN
#endif
)
{