[PATCH 1/8] secur32: Set phNewContext to phContext in schan_InitializeSecurityContextW.

Connor McAdams cmcadams at codeweavers.com
Tue Jan 25 09:32:07 CST 2022


If a valid pointer for phNewContext is passed in alongside a valid phContext
pointer, initialize phNewContext with the value of phContext on success.

Signed-off-by: Connor McAdams <cmcadams at codeweavers.com>
---
 dlls/secur32/schannel.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/dlls/secur32/schannel.c b/dlls/secur32/schannel.c
index 32181b3b35f..6b699cccce1 100644
--- a/dlls/secur32/schannel.c
+++ b/dlls/secur32/schannel.c
@@ -831,6 +831,8 @@ static SECURITY_STATUS SEC_ENTRY schan_InitializeSecurityContextW(
         }
 
         TRACE("Using expected_size %lu.\n", expected_size);
+
+        if (phNewContext) *phNewContext = *phContext;
     }
 
     ctx->req_ctx_attr = fContextReq;
-- 
2.25.1




More information about the wine-devel mailing list