summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Leffler <sam@FreeBSD.org>2003-10-07 20:57:35 +0000
committerSam Leffler <sam@FreeBSD.org>2003-10-07 20:57:35 +0000
commit68974f2940d6af4ad9d99b70a28fc6176b94bd57 (patch)
treea9d8c6e69470f1ed6bc32385a67b8b8fe4e1d734
parentaa15ec9156c3995b33bfa4afd0d1f8768f4d2951 (diff)
Notes
-rw-r--r--sys/netinet6/ip6_output.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/netinet6/ip6_output.c b/sys/netinet6/ip6_output.c
index a7050e3f6198..47376d55ade2 100644
--- a/sys/netinet6/ip6_output.c
+++ b/sys/netinet6/ip6_output.c
@@ -609,6 +609,7 @@ skip_ipsec2:;
/* XXX in6_ifstat_inc(ifp, ifs6_out_discard); */
goto bad;
}
+ /* XXX rt not locked */
ia = ifatoia6(ro->ro_rt->rt_ifa);
ifp = ro->ro_rt->rt_ifp;
ro->ro_rt->rt_use++;
@@ -694,10 +695,11 @@ skip_ipsec2:;
* ``net'' ff00::/8).
*/
if (ifp == NULL) {
- if (ro->ro_rt == 0) {
+ if (ro->ro_rt == 0)
ro->ro_rt = rtalloc1((struct sockaddr *)
&ro->ro_dst, 0, 0UL);
- }
+ else
+ RT_LOCK(ro->ro_rt);
if (ro->ro_rt == 0) {
ip6stat.ip6s_noroute++;
error = EHOSTUNREACH;