summaryrefslogtreecommitdiff
path: root/sys/net/route.h
diff options
context:
space:
mode:
authorJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2001-01-19 06:37:39 +0000
committerJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2001-01-19 06:37:39 +0000
commit70e4be3ea2932a4a2c3c8e85675ba6fe3eb8edcc (patch)
tree72015846dbf72703cf304b4efe000aafa7d8a2ca /sys/net/route.h
parent1ec03c593543ff3451fb2102f094e2e24f111e46 (diff)
pull post-4.4BSD change to sys/net/route.c from BSD/OS 4.2 (UCB copyrighted).
have sys/net/route.c:rtrequest1(), which takes rt_addrinfo * as the argument. pass rt_addrinfo all the way down to rtrequest, and ifa->ifa_rtrequest. 3rd arg of ifa->ifa_rtrequest is now rt_addrinfo * instead of sockaddr * (almost noone is using it anyways). benefit: the follwoing command now works. previously we need two route(8) invocations, "add" then "change". # route add -inet6 default ::1 -ifp gif0 remove unsafe typecast in rtrequest(), from rtentry * to sockaddr *. it was introduced by 4.3BSD-reno and never corrected. XXX is eon_rtrequest() change correct regarding to 3rd arg? eon_rtrequest() and rtrequest() were incorrect since 4.3BSD-reno, so i do not have correct answer in the source code. someone with more clue about netiso-over-ip, please help.
Diffstat (limited to 'sys/net/route.h')
-rw-r--r--sys/net/route.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/sys/net/route.h b/sys/net/route.h
index 43850470ff3..de946b154c2 100644
--- a/sys/net/route.h
+++ b/sys/net/route.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: route.h,v 1.10 2000/12/09 03:15:25 itojun Exp $ */
+/* $OpenBSD: route.h,v 1.11 2001/01/19 06:37:36 itojun Exp $ */
/* $NetBSD: route.h,v 1.9 1996/02/13 22:00:49 christos Exp $ */
/*
@@ -229,6 +229,10 @@ struct rt_msghdr {
struct rt_addrinfo {
int rti_addrs;
struct sockaddr *rti_info[RTAX_MAX];
+ int rti_flags;
+ struct ifaddr *rti_ifa;
+ struct ifnet *rti_ifp;
+ struct rt_msghdr *rti_rtm;
};
struct route_cb {
@@ -313,6 +317,7 @@ void rtalloc_noclone __P((struct route *, int));
struct rtentry *
rtalloc2 __P((struct sockaddr *, int, int));
void rtfree __P((struct rtentry *));
+int rt_getifa __P((struct rt_addrinfo *));
int rtinit __P((struct ifaddr *, int, int));
int rtioctl __P((u_long, caddr_t, struct proc *));
void rtredirect __P((struct sockaddr *, struct sockaddr *,
@@ -321,4 +326,5 @@ void rtredirect __P((struct sockaddr *, struct sockaddr *,
int rtrequest __P((int, struct sockaddr *,
struct sockaddr *, struct sockaddr *, int,
struct rtentry **));
+int rtrequest1 __P((int, struct rt_addrinfo *, struct rtentry **));
#endif /* _KERNEL */