aboutsummaryrefslogtreecommitdiff
path: root/src/or/main.c
diff options
context:
space:
mode:
authorRoger Dingledine <arma@torproject.org>2011-05-16 12:58:44 -0400
committerRoger Dingledine <arma@torproject.org>2011-05-17 20:48:46 -0400
commit07c5026efa4c5fac64e5f3e843eae6bea0de54db (patch)
tree9252e503cd3368cbd7c537b1061da0679acd2f9c /src/or/main.c
parentbc89ef0ca8164f9e6e23e73c01bdb4257fdbce7c (diff)
downloadtor-07c5026efa4c5fac64e5f3e843eae6bea0de54db.tar.gz
tor-07c5026efa4c5fac64e5f3e843eae6bea0de54db.zip
refetch bridge descriptors in a timely fashion
When we configure a new bridge via the controller, don't wait up to ten seconds before trying to fetch its descriptor. This wasn't so bad when you listed your bridges in torrc, but it's dreadful if you configure your bridges via vidalia.
Diffstat (limited to 'src/or/main.c')
-rw-r--r--src/or/main.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/or/main.c b/src/or/main.c
index d700f0e7a8..2c950245ac 100644
--- a/src/or/main.c
+++ b/src/or/main.c
@@ -924,8 +924,6 @@ run_scheduled_events(time_t now)
if (time_to_try_getting_descriptors < now) {
update_router_descriptor_downloads(now);
update_extrainfo_downloads(now);
- if (options->UseBridges)
- fetch_bridge_descriptors(options, now);
if (router_have_minimum_dir_info())
time_to_try_getting_descriptors = now + LAZY_DESCRIPTOR_RETRY_INTERVAL;
else
@@ -938,6 +936,9 @@ run_scheduled_events(time_t now)
now + DESCRIPTOR_FAILURE_RESET_INTERVAL;
}
+ if (options->UseBridges)
+ fetch_bridge_descriptors(options, now);
+
/** 1b. Every MAX_SSL_KEY_LIFETIME seconds, we change our TLS context. */
if (!last_rotated_x509_certificate)
last_rotated_x509_certificate = now;