diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2020-12-03 11:44:31 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2020-12-03 21:53:35 +0300 |
commit | 391119fb5c5c4bdb4d57c7ffeb5e8d18560783d1 (patch) | |
tree | 532e05f8902c8e045733fb33d8fd7e6ed61f1dbd /drivers/net/ethernet/marvell | |
parent | 832e09798c261cf58de3a68cfcc6556408c16a5a (diff) | |
download | linux-391119fb5c5c4bdb4d57c7ffeb5e8d18560783d1.tar.xz |
chelsio/chtls: fix a double free in chtls_setkey()
The "skb" is freed by the transmit code in cxgb4_ofld_send() and we
shouldn't use it again. But in the current code, if we hit an error
later on in the function then the clean up code will call kfree_skb(skb)
and so it causes a double free.
Set the "skb" to NULL and that makes the kfree_skb() a no-op.
Fixes: d25f2f71f653 ("crypto: chtls - Program the TLS session Key")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Link: https://lore.kernel.org/r/X8ilb6PtBRLWiSHp@mwanda
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/ethernet/marvell')
0 files changed, 0 insertions, 0 deletions