diff options
author | Roger Dingledine <arma@torproject.org> | 2009-09-19 23:00:28 -0400 |
---|---|---|
committer | Roger Dingledine <arma@torproject.org> | 2009-12-21 03:52:33 -0500 |
commit | cc73bc385331c09de3d12296db3731e89b7aff35 (patch) | |
tree | f187b568b5e5b50427aa9fcbf351bc9e789e9043 /src | |
parent | 7346804ec65c69fa464d37ccdeeb41736671e00e (diff) | |
download | tor-cc73bc385331c09de3d12296db3731e89b7aff35.tar.gz tor-cc73bc385331c09de3d12296db3731e89b7aff35.zip |
Use nodes in EntryNodes even if they're not fast/stable
Diffstat (limited to 'src')
-rw-r--r-- | src/or/circuitbuild.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/or/circuitbuild.c b/src/or/circuitbuild.c index 3ef6e7e5ce..8a1864ce87 100644 --- a/src/or/circuitbuild.c +++ b/src/or/circuitbuild.c @@ -2854,6 +2854,7 @@ entry_is_live(entry_guard_t *e, int need_uptime, int need_capacity, int assume_reachable, const char **msg) { routerinfo_t *r; + or_options_t *options = get_options(); tor_assert(msg); if (e->bad_since) { @@ -2879,6 +2880,11 @@ entry_is_live(entry_guard_t *e, int need_uptime, int need_capacity, *msg = "not general-purpose"; return NULL; } + if (options->EntryNodes && + routerset_contains_router(options->EntryNodes, r)) { + /* they asked for it, they get it */ + need_uptime = need_capacity = 0; + } if (router_is_unreliable(r, need_uptime, need_capacity, 0)) { *msg = "not fast/stable"; return NULL; |