From 88a1ecb69539358b3525390b07636be9d91ff3bd Mon Sep 17 00:00:00 2001 From: Juan Lang Date: Thu, 16 Oct 2008 08:37:37 -0700 Subject: [PATCH] crypt32: Fix a few more test failures. --- dlls/crypt32/tests/encode.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/dlls/crypt32/tests/encode.c b/dlls/crypt32/tests/encode.c index d568eb57c06..e08a7ce6f9c 100644 --- a/dlls/crypt32/tests/encode.c +++ b/dlls/crypt32/tests/encode.c @@ -469,7 +469,7 @@ static void testTimeEncoding(DWORD dwEncoding, LPCSTR structType, } } else - ok(!ret && GetLastError() == CRYPT_E_BAD_ENCODE, + ok((!ret && GetLastError() == CRYPT_E_BAD_ENCODE) || broken(ret), "Expected CRYPT_E_BAD_ENCODE, got 0x%08x\n", GetLastError()); } @@ -526,7 +526,8 @@ static void testTimeDecoding(DWORD dwEncoding, LPCSTR structType, { ok(ret, "CryptDecodeObjectEx failed: %d (0x%08x)\n", GetLastError(), GetLastError()); - compareTime(&time->sysTime, &ft); + if (ret) + compareTime(&time->sysTime, &ft); } else ok(!ret && (GetLastError() == CRYPT_E_ASN1_BADTAG || @@ -5698,8 +5699,8 @@ static void test_decodePKCSContentInfo(DWORD dwEncoding) /* Native fails with CRYPT_E_ASN1_EOD, accept also CRYPT_E_ASN1_CORRUPT as * I doubt an app depends on that. */ - ok(!ret && (GetLastError() == CRYPT_E_ASN1_EOD || - GetLastError() == CRYPT_E_ASN1_CORRUPT), + ok((!ret && (GetLastError() == CRYPT_E_ASN1_EOD || + GetLastError() == CRYPT_E_ASN1_CORRUPT)) || broken(ret), "Expected CRYPT_E_ASN1_EOD or CRYPT_E_ASN1_CORRUPT, got %x\n", GetLastError()); ret = pCryptDecodeObjectEx(dwEncoding, PKCS_CONTENT_INFO, -- 2.11.4.GIT