diff options
author | Nick Mathewson <nickm@torproject.org> | 2013-03-18 14:50:36 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2013-03-18 14:50:36 -0400 |
commit | f15d9cf5db290f4e1c9ee80214674414238eabff (patch) | |
tree | dc4afd8f76faf80740952c0b3d0a51824d8a5751 /src/or/routerlist.c | |
parent | 15127476561a18a7074d8022f7b80ddfabbdc29b (diff) | |
parent | 26639b7798b5f5dae93e40bd7d050cb218a8aad2 (diff) | |
download | tor-f15d9cf5db290f4e1c9ee80214674414238eabff.tar.gz tor-f15d9cf5db290f4e1c9ee80214674414238eabff.zip |
Merge remote-tracking branch 'origin/maint-0.2.4'
Diffstat (limited to 'src/or/routerlist.c')
-rw-r--r-- | src/or/routerlist.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/or/routerlist.c b/src/or/routerlist.c index f9bf5774a9..854f85cf3f 100644 --- a/src/or/routerlist.c +++ b/src/or/routerlist.c @@ -1150,6 +1150,7 @@ router_pick_directory_server_impl(dirinfo_type_t type, int flags) int requireother = ! (flags & PDS_ALLOW_SELF); int fascistfirewall = ! (flags & PDS_IGNORE_FASCISTFIREWALL); int prefer_tunnel = (flags & PDS_PREFER_TUNNELED_DIR_CONNS_); + int for_guard = (flags & PDS_FOR_GUARD); int try_excluding = 1, n_excluded = 0; if (!consensus) @@ -1189,6 +1190,8 @@ router_pick_directory_server_impl(dirinfo_type_t type, int flags) if ((type & MICRODESC_DIRINFO) && !is_trusted && !node->rs->version_supports_microdesc_cache) continue; + if (for_guard && node->using_as_guard) + continue; /* Don't make the same node a guard twice. */ if (try_excluding && routerset_contains_routerstatus(options->ExcludeNodes, status, country)) { |