summaryrefslogtreecommitdiff
path: root/include/net/aligned_data.h
diff options
context:
space:
mode:
authorZilin Guan <zilin@seu.edu.cn>2025-12-24 12:48:26 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2026-01-17 16:31:22 +0100
commite1a436981ac9552bd25ce18e601140c2716e8400 (patch)
treee21c7a58c8c70c1a7138a4019acbda388713e599 /include/net/aligned_data.h
parentcdafa52ad39b76b94dd72f79316953c774e84982 (diff)
netfilter: nf_tables: fix memory leak in nf_tables_newrule()
[ Upstream commit d077e8119ddbb4fca67540f1a52453631a47f221 ] In nf_tables_newrule(), if nft_use_inc() fails, the function jumps to the err_release_rule label without freeing the allocated flow, leading to a memory leak. Fix this by adding a new label err_destroy_flow and jumping to it when nft_use_inc() fails. This ensures that the flow is properly released in this error case. Fixes: 1689f25924ada ("netfilter: nf_tables: report use refcount overflow") Signed-off-by: Zilin Guan <zilin@seu.edu.cn> Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'include/net/aligned_data.h')
0 files changed, 0 insertions, 0 deletions