summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormpi <mpi@openbsd.org>2015-10-22 16:49:26 +0000
committermpi <mpi@openbsd.org>2015-10-22 16:49:26 +0000
commit440ab99b15741693530426d826d56c2849c9738c (patch)
tree932420534e5ca0c9874c3e5f37355ad44d820ac6
parentMake sure that the address matching the key (destination) of a route (diff)
downloadwireguard-openbsd-440ab99b15741693530426d826d56c2849c9738c.tar.xz
wireguard-openbsd-440ab99b15741693530426d826d56c2849c9738c.zip
Only check for rt_ifp now that it is alays the same as rt_ifa->ifa_ifp.
ok millert@, bluhm@
-rw-r--r--sys/net/route.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/net/route.c b/sys/net/route.c
index 9af588ccaae..c71cc910153 100644
--- a/sys/net/route.c
+++ b/sys/net/route.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: route.c,v 1.256 2015/10/22 16:32:41 mpi Exp $ */
+/* $OpenBSD: route.c,v 1.257 2015/10/22 16:49:26 mpi Exp $ */
/* $NetBSD: route.c,v 1.14 1996/02/13 22:00:46 christos Exp $ */
/*
@@ -1653,8 +1653,7 @@ rt_if_linkstate_change(struct rtentry *rt, void *arg, u_int id)
{
struct ifnet *ifp = arg;
- if ((rt->rt_ifp != ifp) &&
- (rt->rt_ifa == NULL || rt->rt_ifa->ifa_ifp != ifp))
+ if (rt->rt_ifp != ifp)
return (0);
/* Local routes are always usable. */