aboutsummaryrefslogtreecommitdiff
path: root/src/feature/nodelist
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2021-11-09 08:54:11 -0500
committerNick Mathewson <nickm@torproject.org>2021-11-09 09:06:25 -0500
commit08d452b38c84c6522b9ec4b0ebae29c5bba6c83d (patch)
tree3edda1633c3c22f835b1f464e475de654525ea5e /src/feature/nodelist
parentdb7d067ab178e90163bd013c3892ca707a846433 (diff)
downloadtor-08d452b38c84c6522b9ec4b0ebae29c5bba6c83d.tar.gz
tor-08d452b38c84c6522b9ec4b0ebae29c5bba6c83d.zip
Stop using published_on in rs to decide whether to download a routerdesc.
The consensus voters shouldn't actually include such old routers in the consensus anyway, so this logic shouldn't come up... but if a client _does_ download something it wouldn't use, it won't retry infinitely: see checks for WRA_NEVER_DOWNLOADABLE.
Diffstat (limited to 'src/feature/nodelist')
-rw-r--r--src/feature/nodelist/networkstatus.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/feature/nodelist/networkstatus.c b/src/feature/nodelist/networkstatus.c
index d57db4c415..d4a37c4db9 100644
--- a/src/feature/nodelist/networkstatus.c
+++ b/src/feature/nodelist/networkstatus.c
@@ -2615,15 +2615,12 @@ networkstatus_parse_flavor_name(const char *flavname)
int
client_would_use_router(const routerstatus_t *rs, time_t now)
{
+ (void) now;
if (!rs->is_flagged_running) {
/* If we had this router descriptor, we wouldn't even bother using it.
* (Fetching and storing depends on by we_want_to_fetch_flavor().) */
return 0;
}
- if (rs->published_on + OLD_ROUTER_DESC_MAX_AGE < now) {
- /* We'd drop it immediately for being too old. */
- return 0;
- }
if (!routerstatus_version_supports_extend2_cells(rs, 1)) {
/* We'd ignore it because it doesn't support EXTEND2 cells.
* If we don't know the version, download the descriptor so we can