diff options
author | Jun-ichiro itojun Hagino <itojun@cvs.openbsd.org> | 2001-01-19 06:37:39 +0000 |
---|---|---|
committer | Jun-ichiro itojun Hagino <itojun@cvs.openbsd.org> | 2001-01-19 06:37:39 +0000 |
commit | 70e4be3ea2932a4a2c3c8e85675ba6fe3eb8edcc (patch) | |
tree | 72015846dbf72703cf304b4efe000aafa7d8a2ca /sys/netinet6 | |
parent | 1ec03c593543ff3451fb2102f094e2e24f111e46 (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/netinet6')
-rw-r--r-- | sys/netinet6/nd6.c | 10 | ||||
-rw-r--r-- | sys/netinet6/nd6.h | 7 |
2 files changed, 6 insertions, 11 deletions
diff --git a/sys/netinet6/nd6.c b/sys/netinet6/nd6.c index bef280d7480..1ea4937f690 100644 --- a/sys/netinet6/nd6.c +++ b/sys/netinet6/nd6.c @@ -1,4 +1,4 @@ -/* $OpenBSD: nd6.c,v 1.19 2000/10/15 15:55:03 itojun Exp $ */ +/* $OpenBSD: nd6.c,v 1.20 2001/01/19 06:37:38 itojun Exp $ */ /* $KAME: nd6.c,v 1.75 2000/10/15 15:23:11 itojun Exp $ */ /* @@ -1013,10 +1013,10 @@ nd6_resolve(ifp, rt, m, dst, desten) #endif /* OLDIP6OUTPUT */ void -nd6_rtrequest(req, rt, sa) +nd6_rtrequest(req, rt, info) int req; struct rtentry *rt; - struct sockaddr *sa; /* xxx unused */ + struct rt_addrinfo *info; /* xxx unused */ { struct sockaddr *gate = rt->rt_gateway; struct llinfo_nd6 *ln = (struct llinfo_nd6 *)rt->rt_llinfo; @@ -1235,10 +1235,10 @@ nd6_rtrequest(req, rt, sa) } void -nd6_p2p_rtrequest(req, rt, sa) +nd6_p2p_rtrequest(req, rt, info) int req; struct rtentry *rt; - struct sockaddr *sa; /* xxx unused */ + struct rt_addrinfo *info; /* xxx unused */ { struct sockaddr *gate = rt->rt_gateway; static struct sockaddr_dl null_sdl = {sizeof(null_sdl), AF_LINK}; diff --git a/sys/netinet6/nd6.h b/sys/netinet6/nd6.h index 340f4c3f50e..3e44d94db02 100644 --- a/sys/netinet6/nd6.h +++ b/sys/netinet6/nd6.h @@ -1,4 +1,4 @@ -/* $OpenBSD: nd6.h,v 1.8 2000/07/06 10:11:26 itojun Exp $ */ +/* $OpenBSD: nd6.h,v 1.9 2001/01/19 06:37:38 itojun Exp $ */ /* $KAME: nd6.h,v 1.23 2000/06/04 12:54:57 itojun Exp $ */ /* @@ -282,13 +282,8 @@ void nd6_free __P((struct rtentry *)); void nd6_nud_hint __P((struct rtentry *, struct in6_addr *, int)); int nd6_resolve __P((struct ifnet *, struct rtentry *, struct mbuf *, struct sockaddr *, u_char *)); -#if defined(__bsdi__) && _BSDI_VERSION >= 199802 void nd6_rtrequest __P((int, struct rtentry *, struct rt_addrinfo *)); void nd6_p2p_rtrequest __P((int, struct rtentry *, struct rt_addrinfo *)); -#else -void nd6_rtrequest __P((int, struct rtentry *, struct sockaddr *)); -void nd6_p2p_rtrequest __P((int, struct rtentry *, struct sockaddr *)); -#endif int nd6_ioctl __P((u_long, caddr_t, struct ifnet *)); struct rtentry *nd6_cache_lladdr __P((struct ifnet *, struct in6_addr *, char *, int, int, int)); |