Commit 53b7babc authored by Juan Lang's avatar Juan Lang Committed by Alexandre Julliard

crypt32: Don't fail if buffer is NULL, just return required size.

parent 851e19b3
......@@ -2037,7 +2037,9 @@ BOOL WINAPI CertGetValidUsages(DWORD cCerts, PCCERT_CONTEXT *rghCerts,
}
else
{
if (!rghOIDs || *pcbOIDs < cbOIDs)
if (!rghOIDs)
*pcbOIDs = cbOIDs;
else if (*pcbOIDs < cbOIDs)
{
*pcbOIDs = cbOIDs;
SetLastError(ERROR_MORE_DATA);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment