Hans Leidekker : secur32: Don' t allocate a context handle in AcceptSecurityContext if new and passed in context are the same.
Alexandre Julliard
julliard at winehq.org
Mon Oct 16 14:38:31 CDT 2017
Module: wine
Branch: master
Commit: 4467fd6d232cd715cd63b1ebf74c6013e19563b1
URL: http://source.winehq.org/git/wine.git/?a=commit;h=4467fd6d232cd715cd63b1ebf74c6013e19563b1
Author: Hans Leidekker <hans at codeweavers.com>
Date: Mon Oct 16 10:08:49 2017 +0200
secur32: Don't allocate a context handle in AcceptSecurityContext if new and passed in context are the same.
Signed-off-by: Hans Leidekker <hans at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/secur32/wrapper.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/dlls/secur32/wrapper.c b/dlls/secur32/wrapper.c
index 06a3674..dba6754 100644
--- a/dlls/secur32/wrapper.c
+++ b/dlls/secur32/wrapper.c
@@ -399,7 +399,8 @@ SECURITY_STATUS WINAPI AcceptSecurityContext(
ret = package->provider->fnTableW.AcceptSecurityContext(
cred, phContext ? &myCtxt : NULL, pInput, fContextReq,
TargetDataRep, &myCtxt, pOutput, pfContextAttr, ptsExpiry);
- if (ret == SEC_E_OK || ret == SEC_I_CONTINUE_NEEDED)
+ if ((ret == SEC_E_OK || ret == SEC_I_CONTINUE_NEEDED) &&
+ phNewContext && phNewContext != phContext)
{
SECURITY_STATUS ret2;
ret2 = SECUR32_makeSecHandle(phNewContext, package, &myCtxt);
More information about the wine-cvs
mailing list