From: Roger Dingledine Date: Mon, 25 Aug 2003 06:24:17 +0000 (+0000) Subject: fix a mild memory leak (10 bytes each time an OR connected to an OR) X-Git-Tag: tor-0.0.2pre8~58 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=215ca90c058145f68e7c3ab6e072556a58140194;p=thirdparty%2Ftor.git fix a mild memory leak (10 bytes each time an OR connected to an OR) svn:r410 --- diff --git a/src/or/connection_or.c b/src/or/connection_or.c index 75a02d0d73..dd30278efb 100644 --- a/src/or/connection_or.c +++ b/src/or/connection_or.c @@ -535,6 +535,8 @@ or_handshake_server_process_auth(connection_t *conn) { /* copy all relevant info to conn */ conn->addr = router->addr, conn->port = router->or_port; conn->pkey = crypto_pk_dup_key(router->pkey); + if(conn->address) + free(conn->address); conn->address = strdup(router->address); /* generate a nonce */