Commit 9fffe45c authored by Alex Brainman's avatar Alex Brainman

crypto/x509: do not forget to free cert context

R=golang-dev, krautz, rsc
CC=golang-dev
https://golang.org/cl/5783059
parent 3cea4131
......@@ -45,11 +45,7 @@ func createStoreContext(leaf *Certificate, opts *VerifyOptions) (*syscall.CertCo
}
err = syscall.CertAddCertificateContextToStore(handle, ctx, syscall.CERT_STORE_ADD_ALWAYS, nil)
if err != nil {
return nil, err
}
err = syscall.CertFreeCertificateContext(ctx)
syscall.CertFreeCertificateContext(ctx)
if err != nil {
return nil, err
}
......
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