From: Nick Mathewson Date: Tue, 27 Dec 2016 15:20:13 +0000 (-0500) Subject: Fix double-free on test failure X-Git-Tag: tor-0.3.0.2-alpha~68 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1a45398ffa713ca35e0b2b3b12fcd1143a8ce035;p=thirdparty%2Ftor.git Fix double-free on test failure Found by coverity scan; CID 1398167. --- diff --git a/src/test/test_hs_descriptor.c b/src/test/test_hs_descriptor.c index 360334201e..02a71aa473 100644 --- a/src/test/test_hs_descriptor.c +++ b/src/test/test_hs_descriptor.c @@ -689,6 +689,7 @@ test_decode_intro_point(void *arg) /* Try to decode a junk string. */ { hs_descriptor_free(desc); + desc = NULL; ret = ed25519_keypair_generate(&signing_kp, 0); tt_int_op(ret, ==, 0); desc = helper_build_hs_desc(0, &signing_kp.pubkey);