crypt32: Don't check for no data to decode in CryptDecodeObject{Ex}, doing so masks some errors.
This commit is contained in:
parent
916e47861a
commit
de2a187bb7
|
@ -4979,11 +4979,6 @@ BOOL WINAPI CryptDecodeObject(DWORD dwCertEncodingType, LPCSTR lpszStructType,
|
|||
SetLastError(ERROR_INVALID_PARAMETER);
|
||||
return FALSE;
|
||||
}
|
||||
if (!cbEncoded)
|
||||
{
|
||||
SetLastError(CRYPT_E_ASN1_EOD);
|
||||
return FALSE;
|
||||
}
|
||||
if (cbEncoded > MAX_ENCODED_LEN)
|
||||
{
|
||||
SetLastError(CRYPT_E_ASN1_LARGE);
|
||||
|
@ -5031,11 +5026,6 @@ BOOL WINAPI CryptDecodeObjectEx(DWORD dwCertEncodingType, LPCSTR lpszStructType,
|
|||
SetLastError(ERROR_INVALID_PARAMETER);
|
||||
return FALSE;
|
||||
}
|
||||
if (!cbEncoded)
|
||||
{
|
||||
SetLastError(CRYPT_E_ASN1_EOD);
|
||||
return FALSE;
|
||||
}
|
||||
if (cbEncoded > MAX_ENCODED_LEN)
|
||||
{
|
||||
SetLastError(CRYPT_E_ASN1_LARGE);
|
||||
|
|
|
@ -2636,7 +2636,6 @@ static void testHashToBeSigned(void)
|
|||
}
|
||||
SetLastError(0xdeadbeef);
|
||||
ret = CryptHashToBeSigned(0, 0, NULL, 0, NULL, &size);
|
||||
todo_wine
|
||||
ok(!ret && GetLastError() == ERROR_FILE_NOT_FOUND,
|
||||
"expected ERROR_FILE_NOT_FOUND, got %d\n", GetLastError());
|
||||
SetLastError(0xdeadbeef);
|
||||
|
|
Loading…
Reference in New Issue