aboutsummaryrefslogtreecommitdiff
path: root/src/or/circuitbuild.c
diff options
context:
space:
mode:
authorGeorge Kadianakis <desnacked@gmail.com>2011-11-03 17:16:31 +0100
committerNick Mathewson <nickm@torproject.org>2011-11-03 13:23:50 -0400
commit3ae96845d33b11ded74d0e569a859d8f138b70d9 (patch)
treedbb2bedee6996c637f97c8fedef01836dfe9f7a1 /src/or/circuitbuild.c
parent16dbcafb06205bd193bc2656dfbdaf20865ab203 (diff)
downloadtor-3ae96845d33b11ded74d0e569a859d8f138b70d9.tar.gz
tor-3ae96845d33b11ded74d0e569a859d8f138b70d9.zip
Fix a memleak when fetching descriptors for bridges in ExcludeNodes.
Diffstat (limited to 'src/or/circuitbuild.c')
-rw-r--r--src/or/circuitbuild.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/or/circuitbuild.c b/src/or/circuitbuild.c
index c864fd2497..72ec9e4880 100644
--- a/src/or/circuitbuild.c
+++ b/src/or/circuitbuild.c
@@ -4670,7 +4670,6 @@ launch_direct_bridge_descriptor_fetch(bridge_info_t *bridge)
DIR_PURPOSE_FETCH_SERVERDESC))
return; /* it's already on the way */
- address = tor_dup_addr(&bridge->addr);
if (routerset_contains_bridge(options->ExcludeNodes, bridge)) {
download_status_mark_impossible(&bridge->fetch_status);
log_warn(LD_APP, "Not using bridge at %s: it is in ExcludeNodes.",
@@ -4678,6 +4677,8 @@ launch_direct_bridge_descriptor_fetch(bridge_info_t *bridge)
return;
}
+ address = tor_dup_addr(&bridge->addr);
+
directory_initiate_command(address, &bridge->addr,
bridge->port, 0,
0, /* does not matter */