crypt32(10/17): Set *ppChainContext even on error

Juan Lang juan.lang at gmail.com
Thu Sep 6 12:08:08 CDT 2007


--Juan
-------------- next part --------------
From 2068da40a34587f47258f027c1341763154a55ee Mon Sep 17 00:00:00 2001
From: Juan Lang <juan.lang at gmail.com>
Date: Thu, 6 Sep 2007 10:00:18 -0700
Subject: [PATCH] Set *ppChainContext even on error
---
 dlls/crypt32/chain.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/crypt32/chain.c b/dlls/crypt32/chain.c
index e9870f8..3759877 100644
--- a/dlls/crypt32/chain.c
+++ b/dlls/crypt32/chain.c
@@ -644,13 +644,13 @@ BOOL WINAPI CertGetCertificateChain(HCER
     TRACE("(%p, %p, %p, %p, %p, %08x, %p, %p)\n", hChainEngine, pCertContext,
      pTime, hAdditionalStore, pChainPara, dwFlags, pvReserved, ppChainContext);
 
+    if (ppChainContext)
+        *ppChainContext = NULL;
     if (!pChainPara)
     {
         SetLastError(E_INVALIDARG);
         return FALSE;
     }
-    if (ppChainContext)
-        *ppChainContext = NULL;
     if (!hChainEngine)
         hChainEngine = CRYPT_GetDefaultChainEngine();
     /* FIXME: what about HCCE_LOCAL_MACHINE? */
-- 
1.4.1


More information about the wine-patches mailing list