tls: Fix copy-paste error in tls_device_reencrypt
authorGustavo A. R. Silva <gustavo@embeddedor.com>
Wed, 18 Jul 2018 13:27:41 +0000 (08:27 -0500)
committerDavid S. Miller <davem@davemloft.net>
Fri, 20 Jul 2018 19:12:45 +0000 (12:12 -0700)
It seems that the proper structure to use in this particular
case is *skb_iter* instead of skb.

Addresses-Coverity-ID: 1471906 ("Copy-paste error")
Fixes: 4799ac81e52a ("tls: Add rx inline crypto offload")
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/tls/tls_device.c

index 4995d84..1e968d2 100644 (file)
@@ -615,7 +615,7 @@ static int tls_device_reencrypt(struct sock *sk, struct sk_buff *skb)
                             TLS_CIPHER_AES_GCM_128_TAG_SIZE);
 
                if (skb_iter->decrypted)
-                       skb_store_bits(skb, offset, buf, copy);
+                       skb_store_bits(skb_iter, offset, buf, copy);
 
                offset += copy;
                buf += copy;