summaryrefslogtreecommitdiff
path: root/src/lib/tls/x509.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2018-09-04 19:41:59 -0400
committerNick Mathewson <nickm@torproject.org>2018-09-04 19:45:28 -0400
commitd644c93ae9373f99d95870c7b752b790f8714201 (patch)
tree542b703b6405b704ddbf6354f76d97a05320903a /src/lib/tls/x509.c
parentc50537fd9462af45f0a53aa4f0d5ca03a08fc41e (diff)
downloadtor-d644c93ae9373f99d95870c7b752b790f8714201.tar.gz
tor-d644c93ae9373f99d95870c7b752b790f8714201.zip
Resolve openssl-only memory leaks
Diffstat (limited to 'src/lib/tls/x509.c')
-rw-r--r--src/lib/tls/x509.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/lib/tls/x509.c b/src/lib/tls/x509.c
index 442cdf2c74..0d62ee41af 100644
--- a/src/lib/tls/x509.c
+++ b/src/lib/tls/x509.c
@@ -128,9 +128,8 @@ tor_x509_cert_new,(tor_x509_cert_impl_t *x509_cert))
return cert;
err:
- tor_free(cert);
log_err(LD_CRYPTO, "Couldn't wrap encoded X509 certificate.");
- tor_x509_cert_impl_free(x509_cert);
+ tor_x509_cert_free(cert);
return NULL;
}