Juan Lang : crypt32: Fix test failures on Win2k.

Alexandre Julliard julliard at winehq.org
Thu Dec 3 10:29:50 CST 2009


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

Author: Juan Lang <juan.lang at gmail.com>
Date:   Wed Dec  2 10:06:00 2009 -0800

crypt32: Fix test failures on Win2k.

---

 dlls/crypt32/tests/cert.c |    9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/dlls/crypt32/tests/cert.c b/dlls/crypt32/tests/cert.c
index 4a3b0ae..a107250 100644
--- a/dlls/crypt32/tests/cert.c
+++ b/dlls/crypt32/tests/cert.c
@@ -3256,9 +3256,14 @@ static void testVerifyRevocation(void)
     SetLastError(0xdeadbeef);
     ret = CertVerifyRevocation(X509_ASN_ENCODING, CERT_CONTEXT_REVOCATION_TYPE,
      1, (void **)&certs[1], 0, &revPara, &status);
-    ok(!ret && GetLastError() == CRYPT_E_NO_REVOCATION_CHECK,
+    /* Win2k thinks the cert is revoked, and it is, except the CRL is out of
+     * date, hence the revocation status should be unknown.
+     */
+    ok(!ret && (GetLastError() == CRYPT_E_NO_REVOCATION_CHECK ||
+     broken(GetLastError() == CRYPT_E_REVOKED /* Win2k */)),
      "expected CRYPT_E_NO_REVOCATION_CHECK, got %08x\n", GetLastError());
-    ok(status.dwError == CRYPT_E_NO_REVOCATION_CHECK,
+    ok(status.dwError == CRYPT_E_NO_REVOCATION_CHECK ||
+     broken(status.dwError == CRYPT_E_REVOKED /* Win2k */),
      "expected CRYPT_E_NO_REVOCATION_CHECK, got %08x\n", status.dwError);
     ok(status.dwIndex == 0, "expected index 0, got %d\n", status.dwIndex);
     CertCloseStore(revPara.hCrlStore, 0);




More information about the wine-cvs mailing list