mirror of
https://github.com/reactos/wine.git
synced 2025-02-06 20:19:06 +00:00
crypt32: NULL ptr could leak into function (Coverity).
This commit is contained in:
parent
cd028045f1
commit
aa16c89b29
@ -4628,8 +4628,13 @@ BOOL WINAPI CryptEncodeObjectEx(DWORD dwCertEncodingType, LPCSTR lpszStructType,
|
||||
}
|
||||
|
||||
SetLastError(NOERROR);
|
||||
if (dwFlags & CRYPT_ENCODE_ALLOC_FLAG && pvEncoded)
|
||||
if (dwFlags & CRYPT_ENCODE_ALLOC_FLAG) {
|
||||
if (!pvEncoded) {
|
||||
SetLastError(ERROR_INVALID_PARAMETER);
|
||||
return FALSE;
|
||||
}
|
||||
*(BYTE **)pvEncoded = NULL;
|
||||
}
|
||||
encodeFunc = CRYPT_GetBuiltinEncoder(dwCertEncodingType, lpszStructType);
|
||||
if (!encodeFunc)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user