summaryrefslogtreecommitdiff
path: root/src/or/networkstatus.c
diff options
context:
space:
mode:
authorRoger Dingledine <arma@torproject.org>2008-06-05 09:01:18 +0000
committerRoger Dingledine <arma@torproject.org>2008-06-05 09:01:18 +0000
commit6782682ac6f7f8fc7a3f412ae606d5b21de459d1 (patch)
treec6ebc7a517c342d0e7f2d92d65356d710ac36005 /src/or/networkstatus.c
parent2c84c101963aaaa73657648c17a4551a0d5e1ab8 (diff)
downloadtor-6782682ac6f7f8fc7a3f412ae606d5b21de459d1.tar.gz
tor-6782682ac6f7f8fc7a3f412ae606d5b21de459d1.zip
changing v2 network status doesn't require us to recompute
anything about whether enough v3 dir info is here. svn:r14969
Diffstat (limited to 'src/or/networkstatus.c')
-rw-r--r--src/or/networkstatus.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/src/or/networkstatus.c b/src/or/networkstatus.c
index 411199ca58..7dcdcc5dac 100644
--- a/src/or/networkstatus.c
+++ b/src/or/networkstatus.c
@@ -719,7 +719,6 @@ router_set_networkstatus_v2(const char *s, time_t arrived_at,
"downloaded from":"generated for"),
trusted_dir->description, published);
networkstatus_v2_list_has_changed = 1;
- router_dir_info_changed();
smartlist_sort(networkstatus_v2_list,
_compare_networkstatus_v2_published_on);
@@ -757,7 +756,6 @@ networkstatus_v2_list_clean(time_t now)
dirserv_set_cached_networkstatus_v2(NULL, ns->identity_digest, 0);
}
networkstatus_v2_free(ns);
- router_dir_info_changed();
}
/* And now go through the directory cache for any cached untrusted
@@ -1538,11 +1536,11 @@ routers_update_all_from_networkstatus(time_t now, int dir_version)
if (!consensus || dir_version < 3) /* nothing more we should do */
return;
- /* More routers may be up or down now: we need to recalc whether there's
- * enough directory info. */
- router_dir_info_changed();
-
+ /* calls router_dir_info_changed() when it's done -- more routers
+ * might be up or down now, which might affect whether there's enough
+ * directory info. */
routers_update_status_from_consensus_networkstatus(rl->routers, 0);
+
SMARTLIST_FOREACH(rl->routers, routerinfo_t *, ri,
ri->cache_info.routerlist_index = ri_sl_idx);
if (rl->old_routers)