aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoger Dingledine <arma@torproject.org>2006-10-07 07:28:15 +0000
committerRoger Dingledine <arma@torproject.org>2006-10-07 07:28:15 +0000
commit15b4709132111d2b8a044b17b9892d21d4969b26 (patch)
tree8e2164d52d28e2340e4ab31f7ce8633a536dbd4e
parent8fe86704d5550a70730a754eb58f22bd994ae701 (diff)
downloadtor-15b4709132111d2b8a044b17b9892d21d4969b26.tar.gz
tor-15b4709132111d2b8a044b17b9892d21d4969b26.zip
backport 8604:
- When testing reachability of our DirPort, don't launch new tests when there's already one in progress -- unreachable servers were stacking up dozens of testing streams. svn:r8632
-rw-r--r--ChangeLog5
-rw-r--r--src/or/router.c5
2 files changed, 8 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index d74a9a382f..d35e296fb4 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -8,8 +8,11 @@ Changes in version 0.1.1.25 - 2006-10-?? [ongoing]
its circuits on demand.
- If none of our live entry guards have a high uptime, but we
require a guard with a high uptime, try adding a new guard before
- we give up on our requirement. This patch should make long-lived
+ we give up on the requirement. This patch should make long-lived
connections more stable on average.
+ - When testing reachability of our DirPort, don't launch new
+ tests when there's already one in progress -- unreachable
+ servers were stacking up dozens of testing streams.
o Minor bugfixes:
- Avoid a memory corruption bug when creating a hash table for
diff --git a/src/or/router.c b/src/or/router.c
index dd9bde6ff3..2698b578ae 100644
--- a/src/or/router.c
+++ b/src/or/router.c
@@ -461,7 +461,10 @@ consider_testing_reachability(void)
circuit_launch_by_router(CIRCUIT_PURPOSE_TESTING, me, 0, 1, 1);
}
- if (!check_whether_dirport_reachable()) {
+ if (!check_whether_dirport_reachable() &&
+ !connection_get_by_type_addr_port_purpose(
+ CONN_TYPE_DIR, me->addr, me->dir_port,
+ DIR_PURPOSE_FETCH_SERVERDESC)) {
/* ask myself, via tor, for my server descriptor. */
directory_initiate_command_router(me, DIR_PURPOSE_FETCH_SERVERDESC,
1, "authority", NULL, 0);