summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorJunxi Qian <qjx1298677004@gmail.com>2026-04-08 16:10:06 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2026-04-22 13:32:14 +0200
commitaba4712e8f0381cd5d196534ce2ad082626a5ab6 (patch)
treeb511ba6933a513b363dfb6a362f46fd822d11b3a /tools/perf/scripts/python
parent028ef9c96e96197026887c0f092424679298aae8 (diff)
downloadkernel-aba4712e8f0381cd5d196534ce2ad082626a5ab6.tar.gz
nfc: llcp: add missing return after LLCP_CLOSED checks
commit 2b5dd4632966c39da6ba74dbc8689b309065e82c upstream. In nfc_llcp_recv_hdlc() and nfc_llcp_recv_disc(), when the socket state is LLCP_CLOSED, the code correctly calls release_sock() and nfc_llcp_sock_put() but fails to return. Execution falls through to the remainder of the function, which calls release_sock() and nfc_llcp_sock_put() again. This results in a double release_sock() and a refcount underflow via double nfc_llcp_sock_put(), leading to a use-after-free. Add the missing return statements after the LLCP_CLOSED branches in both functions to prevent the fall-through. Fixes: d646960f7986 ("NFC: Initial LLCP support") Signed-off-by: Junxi Qian <qjx1298677004@gmail.com> Reviewed-by: Eric Dumazet <edumazet@google.com> Link: https://patch.msgid.link/20260408081006.3723-1-qjx1298677004@gmail.com Signed-off-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions