rtcalloc() is removed because it turned out not to be necessary for FreeBSD.

(It was added as a part of KAME patch)

Specified by: jdp@polstra.com
This commit is contained in:
Yoshinobu Inoue 1999-12-09 08:56:50 +00:00
parent ababc297fa
commit ae5bcbff16
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=54350
5 changed files with 5 additions and 20 deletions

View File

@ -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.

View File

@ -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 *));

View File

@ -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

View File

@ -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);
}
}

View File

@ -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) {