summaryrefslogtreecommitdiff
path: root/src/or/circuitbuild.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2012-10-04 10:31:25 -0400
committerNick Mathewson <nickm@torproject.org>2012-10-04 10:31:25 -0400
commit03e4b5a9d7ab918dcd121f0ac4586e798e7ff5b0 (patch)
tree0a82ee0eb13313b04d12e7e3d3e0d816758f1e8b /src/or/circuitbuild.c
parentd9847165e0f8b6528acdf3e7246c454c3c4b1597 (diff)
parentce553d49821cf96666afe2380b2409329c71cd8b (diff)
downloadtor-03e4b5a9d7ab918dcd121f0ac4586e798e7ff5b0.tar.gz
tor-03e4b5a9d7ab918dcd121f0ac4586e798e7ff5b0.zip
Merge remote-tracking branch 'linus/bug6757'
Diffstat (limited to 'src/or/circuitbuild.c')
-rw-r--r--src/or/circuitbuild.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/src/or/circuitbuild.c b/src/or/circuitbuild.c
index 230dd8105e..56c2c22d01 100644
--- a/src/or/circuitbuild.c
+++ b/src/or/circuitbuild.c
@@ -5663,15 +5663,9 @@ rewrite_node_address_for_bridge(const bridge_info_t *bridge, node_t *node)
}
}
- /* Mark bridge as preferably connected to over IPv6 if its IPv6
- address is in a Bridge line and ClientPreferIPv6ORPort is
- set. Unless both is true, a potential IPv6 OR port of this
- bridge won't get selected.
-
- XXX ipv6_preferred is never reset (#6757) */
- if (get_options()->ClientPreferIPv6ORPort == 1 &&
- tor_addr_family(&bridge->addr) == AF_INET6)
- node->ipv6_preferred = 1;
+ /* Mark which address to use based on which bridge_t we got. */
+ node->ipv6_preferred = (tor_addr_family(&bridge->addr) == AF_INET6 &&
+ !tor_addr_is_null(&node->ri->ipv6_addr));
/* XXXipv6 we lack support for falling back to another address for
the same relay, warn the user */