tor

The Tor anonymity network
git clone https://git.dasho.dev/tor.git
Log | Files | Refs | README | LICENSE

commit 2484d1eb35d9a54d0e417466148c8480a4816ab7
parent 37f26aa4700eefa59bb548065dcbb4b98add9a55
Author: Nick Mathewson <nickm@torproject.org>
Date:   Wed, 24 Jan 2018 12:08:39 -0500

Fix a memory leak in build_unopened_fourhop

This is a unit-test-only leak, but let's fix it anyway so it doesn't
hide real bugs.

Bug not in any released version of Tor.

Diffstat:
Msrc/test/test_circuitstats.c | 2++
1 file changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/test/test_circuitstats.c b/src/test/test_circuitstats.c @@ -82,6 +82,8 @@ build_unopened_fourhop(struct timeval circ_start_time) onion_append_hop(&or_circ->cpath, fakehop); onion_append_hop(&or_circ->cpath, fakehop); + tor_free(fakehop); + return or_circ; }