Module: wine Branch: master Commit: b17629045f9416342ebeb8e6073a1f0b3e8ee9d5 URL: https://gitlab.winehq.org/wine/wine/-/commit/b17629045f9416342ebeb8e6073a1f0...
Author: Rémi Bernon rbernon@codeweavers.com Date: Fri Jan 13 12:13:07 2023 +0100
msv1_0: Avoid double free when SpInitLsaModeContext fails.
---
dlls/msv1_0/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/msv1_0/main.c b/dlls/msv1_0/main.c index e4890d00a42..a877d974486 100644 --- a/dlls/msv1_0/main.c +++ b/dlls/msv1_0/main.c @@ -862,7 +862,7 @@ static NTSTATUS NTAPI ntlm_SpInitLsaModeContext( LSA_SEC_HANDLE cred_handle, LSA }
done: - if (status != SEC_E_OK && status != SEC_I_CONTINUE_NEEDED) + if (status != SEC_E_OK && status != SEC_I_CONTINUE_NEEDED && !ctx_handle && !input) { ntlm_cleanup( ctx ); free( ctx );