mirror of
https://github.com/curl/curl.git
synced 2026-06-05 02:14:16 +03:00
openssl: fix memory leak in servercert
... when failing to get the server certificate.
This commit is contained in:
parent
7c145bb2a0
commit
da2af5c04d
1 changed files with 1 additions and 0 deletions
|
|
@ -2819,6 +2819,7 @@ static CURLcode servercert(struct connectdata *conn,
|
|||
|
||||
connssl->server_cert = SSL_get_peer_certificate(connssl->handle);
|
||||
if(!connssl->server_cert) {
|
||||
BIO_free(mem);
|
||||
if(!strict)
|
||||
return CURLE_OK;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue