aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRuslan Ermilov <ru@FreeBSD.org>2001-06-04 14:13:15 +0000
committerRuslan Ermilov <ru@FreeBSD.org>2001-06-04 14:13:15 +0000
commitffdc316d488066339029033b6221ffde9b7a8e2d (patch)
treea296215fb51f9b1a3ad0094a4bae835b277b0d1a
parentdb6dde63313342f8e83d71203efb92d0de62b1a8 (diff)
When looking for an interface appropriate for the (new or changing)
route in ifa_ifwithroute(), as the last resort, look up the route to the gateway, not destination (to derive the interface from). PR: kern/27852 Submitted by: Iasen Kostoff <tbyte@tbyte.org> MFC after: 2 weeks
Notes
svn path=/head/; revision=77689
-rw-r--r--sys/net/route.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/net/route.c b/sys/net/route.c
index 884f0eb63f1b..7454280a54f4 100644
--- a/sys/net/route.c
+++ b/sys/net/route.c
@@ -425,7 +425,7 @@ ifa_ifwithroute(flags, dst, gateway)
if (ifa == 0)
ifa = ifa_ifwithnet(gateway);
if (ifa == 0) {
- struct rtentry *rt = rtalloc1(dst, 0, 0UL);
+ struct rtentry *rt = rtalloc1(gateway, 0, 0UL);
if (rt == 0)
return (0);
rt->rt_refcnt--;