1
0
Fork 0
mirror of https://github.com/warmcat/libwebsockets.git synced 2025-03-09 00:00:04 +01:00

Subject: ssl: fix x509 memory leaks

Signed-off-by: Petar Paradzik <petar.paradzik@sartura.hr>
This commit is contained in:
Petar Paradzik 2017-10-26 15:19:08 +02:00 committed by Andy Green
parent 00ffebfd24
commit 939436b793

View file

@ -600,5 +600,9 @@ lws_tls_peer_cert_info(struct lws *wsi, enum lws_tls_cert_info type,
{
X509 *x509 = SSL_get_peer_certificate(wsi->ssl);
return lws_tls_openssl_cert_info(x509, type, buf, len);
int rc = lws_tls_openssl_cert_info(x509, type, buf, len);
X509_free(x509);
return rc;
}