Re: [PATCH v2] nfc: change order inside nfc_se_io error path

From: Krzysztof Kozlowski
Date: Tue Mar 07 2023 - 04:20:26 EST


On 06/03/2023 22:26, Fedor Pchelkin wrote:
> cb_context should be freed on the error path in nfc_se_io as stated by
> commit 25ff6f8a5a3b ("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: Krzysztof Kozlowski <krzysztof.kozlowski@xxxxxxxxxx>
> Signed-off-by: Fedor Pchelkin <pchelkin@xxxxxxxxx>


Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@xxxxxxxxxx>

Best regards,
Krzysztof