diff options
author | zhong jiang <zhongjiang@huawei.com> | 2018-09-20 12:57:16 +0300 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2018-09-28 07:46:26 +0300 |
commit | ce1294d981c1467c13b2b698913f35859592308b (patch) | |
tree | 906c8cc8e4de7b552e1abba442d480350b90baf5 /drivers/crypto/chelsio/chtls/chtls_cm.c | |
parent | 4d407b04d4f3900ac9d6379c5f22364a9ef66ba6 (diff) | |
download | linux-ce1294d981c1467c13b2b698913f35859592308b.tar.xz |
crypto: chtls - remove redundant null pointer check before kfree_skb
kfree_skb has taken the null pointer into account. hence it is safe
to remove the redundant null pointer check before kfree_skb.
Signed-off-by: zhong jiang <zhongjiang@huawei.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/chelsio/chtls/chtls_cm.c')
-rw-r--r-- | drivers/crypto/chelsio/chtls/chtls_cm.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/crypto/chelsio/chtls/chtls_cm.c b/drivers/crypto/chelsio/chtls/chtls_cm.c index 0997e166ea57..fd2ae1e0e561 100644 --- a/drivers/crypto/chelsio/chtls/chtls_cm.c +++ b/drivers/crypto/chelsio/chtls/chtls_cm.c @@ -234,8 +234,7 @@ static void chtls_send_reset(struct sock *sk, int mode, struct sk_buff *skb) return; out: - if (skb) - kfree_skb(skb); + kfree_skb(skb); } static void release_tcp_port(struct sock *sk) |