diff options
-rw-r--r-- | sys/net/route.c | 10 | ||||
-rw-r--r-- | sys/net/route.h | 1 | ||||
-rw-r--r-- | sys/netinet6/frag6.c | 2 | ||||
-rw-r--r-- | sys/netinet6/in6_pcb.c | 2 | ||||
-rw-r--r-- | sys/netinet6/ip6_output.c | 10 |
5 files changed, 5 insertions, 20 deletions
diff --git a/sys/net/route.c b/sys/net/route.c index ea1a579..04608f5 100644 --- a/sys/net/route.c +++ b/sys/net/route.c @@ -103,16 +103,6 @@ rtalloc_ign(ro, ignore) ro->ro_rt = rtalloc1(&ro->ro_dst, 1, ignore); } -/* for INET6 */ -void -rtcalloc(ro) - register struct route *ro; -{ - if (ro->ro_rt && ro->ro_rt->rt_ifp && (ro->ro_rt->rt_flags & RTF_UP)) - return; /* XXX */ - ro->ro_rt = rtalloc1(&ro->ro_dst, RTF_CLONING, 0UL); -} - /* * Look up the route that matches the address given * Or, at least try.. Create a cloned route if needed. diff --git a/sys/net/route.h b/sys/net/route.h index ba1bb95..255fbe3 100644 --- a/sys/net/route.h +++ b/sys/net/route.h @@ -283,7 +283,6 @@ int rt_setgate __P((struct rtentry *, struct sockaddr *, struct sockaddr *)); void rtalloc __P((struct route *)); void rtalloc_ign __P((struct route *, u_long)); -void rtcalloc __P((struct route *)); /* for INET6 */ struct rtentry * rtalloc1 __P((struct sockaddr *, int, u_long)); void rtfree __P((struct rtentry *)); diff --git a/sys/netinet6/frag6.c b/sys/netinet6/frag6.c index 390ab13e..f7cfbc0 100644 --- a/sys/netinet6/frag6.c +++ b/sys/netinet6/frag6.c @@ -133,7 +133,7 @@ frag6_input(mp, offp, proto) dst->sin6_len = sizeof(struct sockaddr_in6); dst->sin6_addr = ip6->ip6_dst; } - rtcalloc((struct route *)&ro); + rtalloc((struct route *)&ro); if (ro.ro_rt != NULL && ro.ro_rt->rt_ifa != NULL) dstifp = ((struct in6_ifaddr *)ro.ro_rt->rt_ifa)->ia_ifp; #else diff --git a/sys/netinet6/in6_pcb.c b/sys/netinet6/in6_pcb.c index ac5b923..8d65ade 100644 --- a/sys/netinet6/in6_pcb.c +++ b/sys/netinet6/in6_pcb.c @@ -614,7 +614,7 @@ in6_selectsrc(dstsock, opts, mopts, ro, laddr, errorp) ro->ro_rt = rtalloc1(&((struct route *)ro) ->ro_dst, 0, 0UL); } else { - rtcalloc((struct route *)ro); + rtalloc((struct route *)ro); } } diff --git a/sys/netinet6/ip6_output.c b/sys/netinet6/ip6_output.c index 1524bc3..b86f0fe 100644 --- a/sys/netinet6/ip6_output.c +++ b/sys/netinet6/ip6_output.c @@ -530,12 +530,8 @@ skip_ipsec2:; * if an interface is specified from an upper layer, * ifp must point it. */ - if (ro->ro_rt == 0) { - if (ro == &ip6route) /* xxx kazu */ - rtalloc((struct route *)ro); - else - rtcalloc((struct route *)ro); - } + if (ro->ro_rt == 0) + rtalloc((struct route *)ro); if (ro->ro_rt == 0) { ip6stat.ip6s_noroute++; error = EHOSTUNREACH; @@ -705,7 +701,7 @@ skip_ipsec2:; sin6_fin->sin6_len = sizeof(struct sockaddr_in6); sin6_fin->sin6_addr = finaldst; - rtcalloc((struct route *)ro_pmtu); + rtalloc((struct route *)ro_pmtu); } } if (ro_pmtu->ro_rt != NULL) { |