Commit c61e89ac authored by Íñigo Huguet's avatar Íñigo Huguet Committed by Zheng Zengkai
Browse files

net:CXGB4: fix leak if sk_buff is not used



stable inclusion
from stable-5.10.39
commit 027926f4ff864e0cde03a4e72babb511c7454394
bugzilla: 51881
CVE: NA

--------------------------------

[ Upstream commit 52bfcdd8 ]

An sk_buff is allocated to send a flow control message, but it's not
sent in all cases: in case the state is not appropiate to send it or if
it can't be enqueued.

In the first of these 2 cases, the sk_buff was discarded but not freed,
producing a memory leak.

Signed-off-by: default avatarÍñigo Huguet <ihuguet@redhat.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarChen Jun <chenjun102@huawei.com>
Acked-by: default avatarWeilong Chen <chenweilong@huawei.com>
Signed-off-by: default avatarZheng Zengkai <zhengzengkai@huawei.com>
parent a7d28683
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment