crypt32: Avoid double free in CRYPT_LoadSIP on error path (coverity).
This commit is contained in:
parent
3dd7c64c25
commit
e078c872a0
|
@ -634,14 +634,17 @@ static BOOL CRYPT_LoadSIP(const GUID *pgSubject)
|
||||||
if (!sip.pfPut || temp != lib)
|
if (!sip.pfPut || temp != lib)
|
||||||
goto error;
|
goto error;
|
||||||
FreeLibrary(temp);
|
FreeLibrary(temp);
|
||||||
|
temp = NULL;
|
||||||
sip.pfCreate = CRYPT_LoadSIPFunc(pgSubject, szCreate, &temp);
|
sip.pfCreate = CRYPT_LoadSIPFunc(pgSubject, szCreate, &temp);
|
||||||
if (!sip.pfCreate || temp != lib)
|
if (!sip.pfCreate || temp != lib)
|
||||||
goto error;
|
goto error;
|
||||||
FreeLibrary(temp);
|
FreeLibrary(temp);
|
||||||
|
temp = NULL;
|
||||||
sip.pfVerify = CRYPT_LoadSIPFunc(pgSubject, szVerify, &temp);
|
sip.pfVerify = CRYPT_LoadSIPFunc(pgSubject, szVerify, &temp);
|
||||||
if (!sip.pfVerify || temp != lib)
|
if (!sip.pfVerify || temp != lib)
|
||||||
goto error;
|
goto error;
|
||||||
FreeLibrary(temp);
|
FreeLibrary(temp);
|
||||||
|
temp = NULL;
|
||||||
sip.pfRemove = CRYPT_LoadSIPFunc(pgSubject, szRemoveSigned, &temp);
|
sip.pfRemove = CRYPT_LoadSIPFunc(pgSubject, szRemoveSigned, &temp);
|
||||||
if (!sip.pfRemove || temp != lib)
|
if (!sip.pfRemove || temp != lib)
|
||||||
goto error;
|
goto error;
|
||||||
|
|
Loading…
Reference in New Issue