diff options
author | Yunfeng Ye <yeyunfeng@huawei.com> | 2019-10-11 15:44:53 +0300 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2019-10-23 11:46:57 +0300 |
commit | fcf801cc551a05a439f819d91b5f853a49c8d243 (patch) | |
tree | 68668bad304be0bdfc07dc27df6a8ccd97c6671c /drivers/crypto/chelsio/chtls | |
parent | b981744ef04f7e8cb6931edab50021fff3c8077e (diff) | |
download | linux-fcf801cc551a05a439f819d91b5f853a49c8d243.tar.xz |
crypto: chtls - remove the redundant check in chtls_recvmsg()
A warning message reported by a static analysis tool:
"
Either the condition 'if(skb)' is redundant or there is possible null
pointer dereference: skb.
"
Remove the unused redundant check.
Signed-off-by: Yunfeng Ye <yeyunfeng@huawei.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/chelsio/chtls')
-rw-r--r-- | drivers/crypto/chelsio/chtls/chtls_io.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/crypto/chelsio/chtls/chtls_io.c b/drivers/crypto/chelsio/chtls/chtls_io.c index 2512bfb24d71..e05343206c3a 100644 --- a/drivers/crypto/chelsio/chtls/chtls_io.c +++ b/drivers/crypto/chelsio/chtls/chtls_io.c @@ -1841,8 +1841,7 @@ skip_copy: tp->urg_data = 0; if (avail + offset >= skb->len) { - if (likely(skb)) - chtls_free_skb(sk, skb); + chtls_free_skb(sk, skb); buffers_freed++; if (copied >= target && |