Commit d4d40e43 authored by Tung Nguyen's avatar Tung Nguyen Committed by Greg Kroah-Hartman
Browse files

tipc: fix memory leak in tipc_link_xmit



[ Upstream commit 69ae9472 ]

In case the backlog transmit queue for system-importance messages is overloaded,
tipc_link_xmit() returns -ENOBUFS but the skb list is not purged. This leads to
memory leak and failure when a skb is allocated.

This commit fixes this issue by purging the skb list before tipc_link_xmit()
returns.

Fixes: 365ad353 ("tipc: reduce risk of user starvation during link congestion")
Signed-off-by: default avatarTung Nguyen <tung.quang.nguyen@est.tech>
Link: https://patch.msgid.link/20250403092431.514063-1-tung.quang.nguyen@est.tech


Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 17d5e6e9
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment