summaryrefslogtreecommitdiff
path: root/src/or
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2016-11-04 14:13:30 -0400
committerNick Mathewson <nickm@torproject.org>2016-11-04 14:13:30 -0400
commit29ae8dcf96532eb5be8023a29de404576d5d2339 (patch)
tree4c107a58eaf8a372371cf2ce966f039cb2a56fb0 /src/or
parent954fb99a48ea12a6c1aa48e2ce1a8acf8fbe456b (diff)
downloadtor-29ae8dcf96532eb5be8023a29de404576d5d2339.tar.gz
tor-29ae8dcf96532eb5be8023a29de404576d5d2339.zip
Fix a bunch of leaks in hs_cache/upload_and_download_hs_desc
Diffstat (limited to 'src/or')
-rw-r--r--src/or/hs_descriptor.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/or/hs_descriptor.c b/src/or/hs_descriptor.c
index 0676c71737..3986e8d59c 100644
--- a/src/or/hs_descriptor.c
+++ b/src/or/hs_descriptor.c
@@ -324,8 +324,10 @@ encode_enc_key(const ed25519_keypair_t *sig_key,
goto err;
}
if (encode_cert(cross_cert, &encoded_cert)) {
+ tor_cert_free(cross_cert);
goto err;
}
+ tor_cert_free(cross_cert);
if (curve25519_public_to_base64(key_fp_b64,
&ip->enc_key.curve25519.pubkey) < 0) {
tor_free(encoded_cert);