Juan Lang : crypt32: Ensure that chain validity time is initialized ( valgrind).

Alexandre Julliard julliard at winehq.org
Wed Jan 19 11:46:17 CST 2011


Module: wine
Branch: master
Commit: 98834637eb25caf986c9feae3eaa0b855cc19a26
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=98834637eb25caf986c9feae3eaa0b855cc19a26

Author: Juan Lang <juan.lang at gmail.com>
Date:   Wed Jan 19 09:15:29 2011 -0800

crypt32: Ensure that chain validity time is initialized (valgrind).

---

 dlls/crypt32/tests/chain.c |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/dlls/crypt32/tests/chain.c b/dlls/crypt32/tests/chain.c
index 71be975..d11dece 100644
--- a/dlls/crypt32/tests/chain.c
+++ b/dlls/crypt32/tests/chain.c
@@ -2664,7 +2664,9 @@ static PCCERT_CHAIN_CONTEXT getChain(HCERTCHAINENGINE engine,
             CERT_CHAIN_PARA chainPara = { sizeof(chainPara), { 0 } };
             FILETIME fileTime;
 
-            SystemTimeToFileTime(checkTime, &fileTime);
+            ok(SystemTimeToFileTime(checkTime, &fileTime),
+             "SystemTimeToFileTime failed for day %d, month %d, year %d\n",
+             checkTime->wDay, checkTime->wMonth, checkTime->wYear);
             ret = pCertGetCertificateChain(engine, endCert, &fileTime,
              includeStore ? store : NULL, &chainPara, flags, NULL, &chain);
             if (todo & TODO_CHAIN)
@@ -4340,6 +4342,8 @@ static void check_authenticode_policy(void)
     policyPara.dwFlags = CERT_CHAIN_POLICY_ALLOW_UNKNOWN_CA_FLAG;
     CHECK_CHAIN_POLICY_STATUS(CERT_CHAIN_POLICY_AUTHENTICODE, NULL,
      ignoredUnknownCAPolicyCheck, &oct2007, &policyPara);
+    epochStart.wDay = epochStart.wMonth = 1;
+    epochStart.wYear = 1601;
     CHECK_CHAIN_POLICY_STATUS(CERT_CHAIN_POLICY_AUTHENTICODE, NULL,
      ignoredUnknownCAPolicyCheck, &epochStart, &policyPara);
     policyPara.dwFlags = CERT_CHAIN_POLICY_IGNORE_NOT_TIME_VALID_FLAG;




More information about the wine-cvs mailing list