diff options
author | Arnd Bergmann <arnd@arndb.de> | 2011-07-21 18:31:22 +0400 |
---|---|---|
committer | Arnd Bergmann <arnd@arndb.de> | 2011-07-21 18:31:22 +0400 |
commit | ab2a0e0d135490729e384c1826d118f92e88cae8 (patch) | |
tree | 58ab1e9e5d549feac9bf3beacbb6942f50d0bed9 /net/ipv4/xfrm4_output.c | |
parent | 09dd9b39abf85b8fae3ea105a81825478dd227b6 (diff) | |
parent | 2f3ab04a47c9b5e7c93400601e8f69bef0fa184a (diff) | |
download | linux-ab2a0e0d135490729e384c1826d118f92e88cae8.tar.xz |
Merge branch 'next-samsung-cleanup' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung into next/cleanup
Diffstat (limited to 'net/ipv4/xfrm4_output.c')
-rw-r--r-- | net/ipv4/xfrm4_output.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/net/ipv4/xfrm4_output.c b/net/ipv4/xfrm4_output.c index 2d51840e53a1..327a617d594c 100644 --- a/net/ipv4/xfrm4_output.c +++ b/net/ipv4/xfrm4_output.c @@ -32,7 +32,12 @@ static int xfrm4_tunnel_check_size(struct sk_buff *skb) dst = skb_dst(skb); mtu = dst_mtu(dst); if (skb->len > mtu) { - icmp_send(skb, ICMP_DEST_UNREACH, ICMP_FRAG_NEEDED, htonl(mtu)); + if (skb->sk) + ip_local_error(skb->sk, EMSGSIZE, ip_hdr(skb)->daddr, + inet_sk(skb->sk)->inet_dport, mtu); + else + icmp_send(skb, ICMP_DEST_UNREACH, + ICMP_FRAG_NEEDED, htonl(mtu)); ret = -EMSGSIZE; } out: |