Michael Stefaniuc : crypt32/tests: Avoid an always true ok() condition ( PVS-Studio).
Alexandre Julliard
julliard at wine.codeweavers.com
Mon Nov 3 07:21:48 CST 2014
Module: wine
Branch: master
Commit: 25b4a92813f8ec44d5c0c6112c135f0b903c8e47
URL: http://source.winehq.org/git/wine.git/?a=commit;h=25b4a92813f8ec44d5c0c6112c135f0b903c8e47
Author: Michael Stefaniuc <mstefani at redhat.de>
Date: Sun Nov 2 22:28:15 2014 +0100
crypt32/tests: Avoid an always true ok() condition (PVS-Studio).
---
dlls/crypt32/tests/ctl.c | 16 ++--------------
1 file changed, 2 insertions(+), 14 deletions(-)
diff --git a/dlls/crypt32/tests/ctl.c b/dlls/crypt32/tests/ctl.c
index 55bbc6e..79a60f8 100644
--- a/dlls/crypt32/tests/ctl.c
+++ b/dlls/crypt32/tests/ctl.c
@@ -390,20 +390,8 @@ static void testAddCTLToStore(void)
signedCTLWithCTLInnerContentAndBadSig,
sizeof(signedCTLWithCTLInnerContentAndBadSig), CERT_STORE_ADD_NEW,
NULL);
- if (ret)
- {
- /* win9x */
- ok(GetLastError() == CRYPT_E_NOT_FOUND ||
- GetLastError() == OSS_DATA_ERROR /* some win98 */,
- "Expected CRYPT_E_NOT_FOUND, got %08x\n", GetLastError());
- }
- else
- {
- ok(!ret && (GetLastError() == CRYPT_E_EXISTS ||
- GetLastError() == OSS_DATA_ERROR),
- "expected CRYPT_E_EXISTS or OSS_DATA_ERROR, got %d %08x\n", ret,
- GetLastError());
- }
+ ok(!ret && (GetLastError() == CRYPT_E_EXISTS || GetLastError() == OSS_DATA_ERROR),
+ "expected CRYPT_E_EXISTS or OSS_DATA_ERROR, got %d %08x\n", ret, GetLastError());
CertCloseStore(store, 0);
store = CertOpenStore(CERT_STORE_PROV_MEMORY, 0, 0,
More information about the wine-cvs
mailing list