diff options
Diffstat (limited to 'net/ipv4/xfrm4_output.c')
-rw-r--r-- | net/ipv4/xfrm4_output.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/net/ipv4/xfrm4_output.c b/net/ipv4/xfrm4_output.c index 04805c7d79c3..434ef302ba83 100644 --- a/net/ipv4/xfrm4_output.c +++ b/net/ipv4/xfrm4_output.c | |||
@@ -44,6 +44,7 @@ static inline int xfrm4_output_one(struct sk_buff *skb) | |||
44 | { | 44 | { |
45 | struct dst_entry *dst = skb->dst; | 45 | struct dst_entry *dst = skb->dst; |
46 | struct xfrm_state *x = dst->xfrm; | 46 | struct xfrm_state *x = dst->xfrm; |
47 | struct iphdr *iph; | ||
47 | int err; | 48 | int err; |
48 | 49 | ||
49 | if (x->props.mode == XFRM_MODE_TUNNEL) { | 50 | if (x->props.mode == XFRM_MODE_TUNNEL) { |
@@ -56,6 +57,10 @@ static inline int xfrm4_output_one(struct sk_buff *skb) | |||
56 | if (err) | 57 | if (err) |
57 | goto error_nolock; | 58 | goto error_nolock; |
58 | 59 | ||
60 | iph = ip_hdr(skb); | ||
61 | iph->tot_len = htons(skb->len); | ||
62 | ip_send_check(iph); | ||
63 | |||
59 | IPCB(skb)->flags |= IPSKB_XFRM_TRANSFORMED; | 64 | IPCB(skb)->flags |= IPSKB_XFRM_TRANSFORMED; |
60 | err = 0; | 65 | err = 0; |
61 | 66 | ||