Skip to content

Commit

Permalink
tcp: correctly crypto_alloc_hash return check
Browse files Browse the repository at this point in the history
crypto_alloc_hash never returns NULL

Signed-off-by: Insu Yun <wuninsu@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Insu Yun authored and David S. Miller committed Feb 18, 2016
1 parent 73dcb55 commit 1eea84b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/ipv4/tcp.c
Original file line number Diff line number Diff line change
Expand Up @@ -2950,7 +2950,7 @@ static void __tcp_alloc_md5sig_pool(void)
struct crypto_hash *hash;

hash = crypto_alloc_hash("md5", 0, CRYPTO_ALG_ASYNC);
if (IS_ERR_OR_NULL(hash))
if (IS_ERR(hash))
return;
per_cpu(tcp_md5sig_pool, cpu).md5_desc.tfm = hash;
}
Expand Down

0 comments on commit 1eea84b

Please sign in to comment.