From c229f9dcfe0bcde58a2982ebf2ba4e8947560863 Mon Sep 17 00:00:00 2001 From: Juan Lang Date: Thu, 31 Jul 2008 11:20:25 -0700 Subject: [PATCH] Fix some test failures on Win9x --- dlls/crypt32/tests/chain.c | 17 +++++++++++++++++ 1 files changed, 17 insertions(+), 0 deletions(-) diff --git a/dlls/crypt32/tests/chain.c b/dlls/crypt32/tests/chain.c index 91cae47..5bae989 100644 --- a/dlls/crypt32/tests/chain.c +++ b/dlls/crypt32/tests/chain.c @@ -1741,6 +1741,14 @@ static ChainPolicyCheck basicConstraints { 0, 0, -1, -1, NULL }, 0 }, }; +static const char *num_to_str(WORD num) +{ + static char buf[6]; + + sprintf(buf, "#%04X", num); + return buf; +} + static void checkChainPolicyStatus(LPCSTR policy, ChainPolicyCheck *check, DWORD testIndex) { @@ -1757,8 +1765,17 @@ static void checkChainPolicyStatus(LPCST todo_wine ok(ret, "%d: CertVerifyCertificateChainPolicy failed: %08x\n", testIndex, GetLastError()); else + { + if (!ret && GetLastError() == ERROR_FILE_NOT_FOUND) + { + skip("%d: missing policy %s, skipping test\n", testIndex, + HIWORD(policy) ? policy : num_to_str(LOWORD(policy))); + pCertFreeCertificateChain(chain); + return; + } ok(ret, "%d: CertVerifyCertificateChainPolicy failed: %08x\n", testIndex, GetLastError()); + } if (ret) { if (check->todo & TODO_ERROR) -- 1.4.1