mirror of
https://github.com/golang/go
synced 2024-11-12 06:20:22 -07:00
crypto/x509: do not forget to free cert context
R=golang-dev, krautz, rsc CC=golang-dev https://golang.org/cl/5783059
This commit is contained in:
parent
3cea4131df
commit
9fffe45c65
@ -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
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user