Commit fc14728e authored by Juan Lang's avatar Juan Lang Committed by Alexandre Julliard

crypt32: Fix a leak during chain creation.

parent 4690a9c8
...@@ -913,6 +913,10 @@ static BOOL CRYPT_BuildSimpleChain(PCertificateChainEngine engine, ...@@ -913,6 +913,10 @@ static BOOL CRYPT_BuildSimpleChain(PCertificateChainEngine engine,
if (issuer) if (issuer)
{ {
ret = CRYPT_AddCertToSimpleChain(engine, chain, issuer, infoStatus); ret = CRYPT_AddCertToSimpleChain(engine, chain, issuer, infoStatus);
/* CRYPT_AddCertToSimpleChain add-ref's the issuer, so free it to
* close the enumeration that found it
*/
CertFreeCertificateContext(issuer);
cert = issuer; cert = issuer;
} }
else else
......
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