diff options
author | George Kadianakis <desnacked@riseup.net> | 2020-06-02 14:05:33 +0300 |
---|---|---|
committer | George Kadianakis <desnacked@riseup.net> | 2020-06-02 14:05:33 +0300 |
commit | 6b05d447bb5ee8512b33ed2f78223e02c6455096 (patch) | |
tree | 74bc02e50d0f83b199899d14f175420c34175368 /src/feature/client | |
parent | 688d1b3f032b5a84ad5ada23fa8831c07bd76c75 (diff) | |
parent | 39f2411b3f5ab1a50c74fdafb432d5286c451ab7 (diff) | |
download | tor-6b05d447bb5ee8512b33ed2f78223e02c6455096.tar.gz tor-6b05d447bb5ee8512b33ed2f78223e02c6455096.zip |
Merge branch 'tor-github/pr/1909' into maint-0.4.3
Diffstat (limited to 'src/feature/client')
-rw-r--r-- | src/feature/client/entrynodes.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/feature/client/entrynodes.c b/src/feature/client/entrynodes.c index 749d8881f0..148e6471ba 100644 --- a/src/feature/client/entrynodes.c +++ b/src/feature/client/entrynodes.c @@ -3452,10 +3452,16 @@ entry_guards_update_state(or_state_t *state) entry_guards_dirty = 0; } -/** Return true iff the circuit's guard can succeed that is can be used. */ +/** Return true iff the circuit's guard can succeed, that is, can be used. */ int entry_guard_could_succeed(const circuit_guard_state_t *guard_state) { + if (get_options()->UseEntryGuards == 0) { + /* we're fine with this circuit's first hop, because we're not + * configured to use entry guards. */ + return 1; + } + if (!guard_state) { return 0; } |