]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Don't delay descriptor fetches when missing info needed for circuits
authorNick Mathewson <nickm@torproject.org>
Wed, 8 Nov 2017 18:22:16 +0000 (13:22 -0500)
committerNick Mathewson <nickm@torproject.org>
Wed, 8 Nov 2017 18:22:16 +0000 (13:22 -0500)
When we have fewer than 15 descriptors to fetch, we will delay the
fetch for a little while.  That's fine, if we can go ahead and build
circuits... but if not, it's a poor choice indeed.

Fixes bug 23985; bugfix on 0.1.1.11-alpha.

In 0.3.0.3-alpha, when we made primary guard descriptors necessary
for circuit building, this situation got worse.

changes/bug23985 [new file with mode: 0644]
src/or/routerlist.c

diff --git a/changes/bug23985 b/changes/bug23985
new file mode 100644 (file)
index 0000000..9cb5937
--- /dev/null
@@ -0,0 +1,9 @@
+  o Minor bugfixes (bootstrapping):
+    - Fetch descriptors aggressively whenever we lack enough
+      to build circuits, regardless of how many descriptors we are missing.
+      Previously, we would delay launching the fetch when we had fewer than
+      15 missing descriptors, even if some of those descriptors were
+      blocking circuits from building. Fixes bug 23985; bugfix on
+      0.1.1.11-alpha. The effects of this bug became worse in 0.3.0.3-alpha,
+      when we began treating missing descriptors from our primary guards
+      as a reason to delay circuits.
index 2365f28fd2b726c0cea9d68f43b3be57a4b8ae0f..1b7c81ad5f4f488951703290fac4bf83b3510e67 100644 (file)
@@ -5035,6 +5035,11 @@ launch_descriptor_downloads(int purpose,
       log_debug(LD_DIR,
                 "There are enough downloadable %ss to launch requests.",
                 descname);
+    } else if (! router_have_minimum_dir_info()) {
+      log_debug(LD_DIR,
+                "We are only missing %d %ss, but we'll fetch anyway, since "
+                "we don't yet have enough directory info.",
+                n_downloadable, descname);
     } else {
 
       /* should delay */