aboutsummaryrefslogtreecommitdiff
path: root/src/or
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2013-03-13 09:17:43 -0400
committerNick Mathewson <nickm@torproject.org>2013-03-13 09:17:43 -0400
commitb9a8f8c17ce11dd867e0afec7cbb65c55a3d7e8c (patch)
tree8bae4d2515407f8402c11a9d0c30bbc1750f8923 /src/or
parent7543fb61e34e9235c6c330270d0c370c64c3322a (diff)
downloadtor-b9a8f8c17ce11dd867e0afec7cbb65c55a3d7e8c.tar
tor-b9a8f8c17ce11dd867e0afec7cbb65c55a3d7e8c.tar.gz
Fix the warning about LearnCircuitBuildTimeout && !CircuitBuildTimeout
This is for bug 6304. Add a changes file too
Diffstat (limited to 'src/or')
-rw-r--r--src/or/config.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/or/config.c b/src/or/config.c
index 90a5dfbda..b04a8745f 100644
--- a/src/or/config.c
+++ b/src/or/config.c
@@ -3761,15 +3761,19 @@ options_validate(or_options_t *old_options, or_options_t *options,
options->LearnCircuitBuildTimeout = 0;
}
- if (!(options->LearnCircuitBuildTimeout) &&
- options->CircuitBuildTimeout < RECOMMENDED_MIN_CIRCUIT_BUILD_TIMEOUT) {
+ if (!options->LearnCircuitBuildTimeout && options->CircuitBuildTimeout &&
+ options->CircuitBuildTimeout < RECOMMENDED_MIN_CIRCUIT_BUILD_TIMEOUT) {
log_warn(LD_CONFIG,
- "CircuitBuildTimeout is shorter (%d seconds) than recommended "
- "(%d seconds), and LearnCircuitBuildTimeout is disabled. "
+ "CircuitBuildTimeout is shorter (%d seconds) than the recommended "
+ "minimum (%d seconds), and LearnCircuitBuildTimeout is disabled. "
"If tor isn't working, raise this value or enable "
"LearnCircuitBuildTimeout.",
options->CircuitBuildTimeout,
RECOMMENDED_MIN_CIRCUIT_BUILD_TIMEOUT );
+ } else if (!options->LearnCircuitBuildTimeout &&
+ !options->CircuitBuildTimeout) {
+ log_notice(LD_CONFIG, "You disabled LearnCircuitBuildTimeout, but didn't "
+ "a CircuitBuildTimeout. I'll pick a plausible default.");
}
if (options->MaxCircuitDirtiness < MIN_MAX_CIRCUIT_DIRTINESS) {