summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbluhm <bluhm@openbsd.org>2013-10-19 09:23:59 +0000
committerbluhm <bluhm@openbsd.org>2013-10-19 09:23:59 +0000
commitbde43c77ece7ae1b67acb9dca41992ef595a47ef (patch)
treeed1b01a7bad36cc2ace0f31bb2f092cf3dfc4f53
parentRemove more knowledge of a.out and stab information from the tree. (diff)
downloadwireguard-openbsd-bde43c77ece7ae1b67acb9dca41992ef595a47ef.tar.xz
wireguard-openbsd-bde43c77ece7ae1b67acb9dca41992ef595a47ef.zip
In carp_set_addr6() break out of the loop after the interface address
has been found. This makes the IPv6 code work like IPv4. OK mpi@
-rw-r--r--sys/netinet/ip_carp.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/netinet/ip_carp.c b/sys/netinet/ip_carp.c
index a4793013a8b..756bb6c9172 100644
--- a/sys/netinet/ip_carp.c
+++ b/sys/netinet/ip_carp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ip_carp.c,v 1.211 2013/10/17 16:27:43 bluhm Exp $ */
+/* $OpenBSD: ip_carp.c,v 1.212 2013/10/19 09:23:59 bluhm Exp $ */
/*
* Copyright (c) 2002 Michael Shalayeff. All rights reserved.
@@ -2129,8 +2129,8 @@ carp_set_addr6(struct carp_softc *sc, struct sockaddr_in6 *sin6)
ia->ia_ifp->if_type != IFT_CARP &&
(ia->ia_ifp->if_flags & IFF_MULTICAST) &&
(i == 4)) {
- if (!ia_if)
- ia_if = ia;
+ ia_if = ia;
+ break;
}
}