esp6: fix incorrect null pointer check on xo

The check for xo being null is incorrect, currently it is checking
for non-null, it should be checking for null.

Detected with CoverityScan, CID#1429349 ("Dereference after null check")

Fixes: 7862b4058b ("esp: Add gso handlers for esp4 and esp6")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
This commit is contained in:
Colin Ian King 2017-04-18 15:06:53 +01:00 committed by Steffen Klassert
parent bcd1f8a45e
commit ffa6f571e4
1 changed files with 1 additions and 1 deletions

View File

@ -120,7 +120,7 @@ static struct sk_buff *esp6_gso_segment(struct sk_buff *skb,
netdev_features_t esp_features = features;
struct xfrm_offload *xo = xfrm_offload(skb);
if (xo)
if (!xo)
goto out;
seq = xo->seq.low;