mirror of https://github.com/FreeRDP/FreeRDP
Merge pull request #10463 from akallabeth/ncrypt_checks
[winpr,ncrypt] check p11 for NULL
This commit is contained in:
commit
122c6eaeb9
|
@ -111,7 +111,7 @@ static SECURITY_STATUS NCryptP11StorageProvider_dtor(NCRYPT_HANDLE handle)
|
||||||
|
|
||||||
if (provider)
|
if (provider)
|
||||||
{
|
{
|
||||||
if (provider->p11->C_Finalize)
|
if (provider->p11 && provider->p11->C_Finalize)
|
||||||
rv = provider->p11->C_Finalize(NULL);
|
rv = provider->p11->C_Finalize(NULL);
|
||||||
if (rv != CKR_OK)
|
if (rv != CKR_OK)
|
||||||
{
|
{
|
||||||
|
@ -1217,6 +1217,7 @@ static SECURITY_STATUS initialize_pkcs11(HANDLE handle,
|
||||||
goto fail;
|
goto fail;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
WINPR_ASSERT(ret->p11);
|
||||||
WINPR_ASSERT(ret->p11->C_Initialize);
|
WINPR_ASSERT(ret->p11->C_Initialize);
|
||||||
rv = ret->p11->C_Initialize(NULL);
|
rv = ret->p11->C_Initialize(NULL);
|
||||||
if (rv != CKR_OK)
|
if (rv != CKR_OK)
|
||||||
|
|
Loading…
Reference in New Issue