diff options
author | 2015-11-18 13:05:58 +0000 | |
---|---|---|
committer | 2015-11-18 13:05:58 +0000 | |
commit | 03f2c5bd9128536ce161f71576dc92b41d364e44 (patch) | |
tree | c8307fa861c6bf746e40b0a012c1e2841d363d57 | |
parent | Multipath selection should be done before caching the next hop. (diff) | |
download | wireguard-openbsd-03f2c5bd9128536ce161f71576dc92b41d364e44.tar.xz wireguard-openbsd-03f2c5bd9128536ce161f71576dc92b41d364e44.zip |
Revert previous workaround now that multipath route selection has been
fixed.
ok sthen@, dlg@
-rw-r--r-- | sys/net/route.c | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/sys/net/route.c b/sys/net/route.c index 34abcd70071..a63d4311a7e 100644 --- a/sys/net/route.c +++ b/sys/net/route.c @@ -1,4 +1,4 @@ -/* $OpenBSD: route.c,v 1.272 2015/11/18 12:45:59 mpi Exp $ */ +/* $OpenBSD: route.c,v 1.273 2015/11/18 13:05:58 mpi Exp $ */ /* $NetBSD: route.c,v 1.14 1996/02/13 22:00:46 christos Exp $ */ /* @@ -419,14 +419,8 @@ _rtalloc(struct sockaddr *dst, uint32_t *src, int flags, unsigned int rtableid) return (rt); } - /* Next hop entry must be UP... */ - if (!ISSET(nhrt->rt_flags, RTF_UP)) { - rtfree(nhrt); - return (rt); - } - - /* ...and on the same interface unless we have multiple gateways. */ - if (nhrt->rt_ifidx != rt->rt_ifidx && !ISSET(rt->rt_flags, RTF_MPATH)) { + /* Next hop entry must be UP and on the same interface. */ + if (!ISSET(nhrt->rt_flags, RTF_UP) || nhrt->rt_ifidx != rt->rt_ifidx) { rtfree(nhrt); return (rt); } |