Skip to content
Commit 7d834b4d authored by Fedor Pchelkin's avatar Fedor Pchelkin Committed by Jakub Kicinski
Browse files

nfc: change order inside nfc_se_io error path



cb_context should be freed on the error path in nfc_se_io as stated by
commit 25ff6f8a ("nfc: fix memory leak of se_io context in
nfc_genl_se_io").

Make the error path in nfc_se_io unwind everything in reverse order, i.e.
free the cb_context after unlocking the device.

Suggested-by: default avatarKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: default avatarFedor Pchelkin <pchelkin@ispras.ru>
Reviewed-by: default avatarKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20230306212650.230322-1-pchelkin@ispras.ru


Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent 382e363d
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment