diff options
Diffstat (limited to 'net/ipv4/xfrm4_input.c')
-rw-r--r-- | net/ipv4/xfrm4_input.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/net/ipv4/xfrm4_input.c b/net/ipv4/xfrm4_input.c index 850d919591d1..04ceb6e13b9d 100644 --- a/net/ipv4/xfrm4_input.c +++ b/net/ipv4/xfrm4_input.c | |||
@@ -90,6 +90,9 @@ int xfrm4_rcv_encap(struct sk_buff *skb, __u16 encap_type) | |||
90 | if (unlikely(x->km.state != XFRM_STATE_VALID)) | 90 | if (unlikely(x->km.state != XFRM_STATE_VALID)) |
91 | goto drop_unlock; | 91 | goto drop_unlock; |
92 | 92 | ||
93 | if (x->encap->encap_type != encap_type) | ||
94 | goto drop_unlock; | ||
95 | |||
93 | if (x->props.replay_window && xfrm_replay_check(x, seq)) | 96 | if (x->props.replay_window && xfrm_replay_check(x, seq)) |
94 | goto drop_unlock; | 97 | goto drop_unlock; |
95 | 98 | ||
@@ -97,7 +100,7 @@ int xfrm4_rcv_encap(struct sk_buff *skb, __u16 encap_type) | |||
97 | goto drop_unlock; | 100 | goto drop_unlock; |
98 | 101 | ||
99 | xfrm_vec[xfrm_nr].decap.decap_type = encap_type; | 102 | xfrm_vec[xfrm_nr].decap.decap_type = encap_type; |
100 | if (x->type->input(x, &(xfrm_vec[xfrm_nr].decap), skb)) | 103 | if (x->type->input(x, skb)) |
101 | goto drop_unlock; | 104 | goto drop_unlock; |
102 | 105 | ||
103 | /* only the first xfrm gets the encap type */ | 106 | /* only the first xfrm gets the encap type */ |