[XFRM]: Allow packet drops during larval state resolution.
[deliverable/linux.git] / net / ipv6 / udp.c
index a7ae59c954d5a2d68f7d18c6bdb3addf1abcbdaf..d1fbddd172e76c277625254641e59ae884488f0a 100644 (file)
@@ -767,8 +767,12 @@ do_udp_sendmsg:
        if (final_p)
                ipv6_addr_copy(&fl.fl6_dst, final_p);
 
-       if ((err = xfrm_lookup(&dst, &fl, sk, 1)) < 0)
-               goto out;
+       if ((err = __xfrm_lookup(&dst, &fl, sk, 1)) < 0) {
+               if (err == -EREMOTE)
+                       err = ip6_dst_blackhole(sk, &dst, &fl);
+               if (err < 0)
+                       goto out;
+       }
 
        if (hlimit < 0) {
                if (ipv6_addr_is_multicast(&fl.fl6_dst))
This page took 0.024957 seconds and 5 git commands to generate.