summaryrefslogtreecommitdiff
path: root/src/or/directory.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2005-01-06 20:11:52 +0000
committerNick Mathewson <nickm@torproject.org>2005-01-06 20:11:52 +0000
commit91bafc476ef1e5a6e51c61d4a2b1c206af628ffc (patch)
tree3de6b89854752ea21941288e3b564ed77f699350 /src/or/directory.c
parentf8b517fa9783b2445667d0bb23c22b719e7a428e (diff)
downloadtor-91bafc476ef1e5a6e51c61d4a2b1c206af628ffc.tar.gz
tor-91bafc476ef1e5a6e51c61d4a2b1c206af628ffc.zip
Fix a fun bug: do not rewrite a cached directory back to the cache; otherwise we will think it is recent and not fetch a newer one.
svn:r3319
Diffstat (limited to 'src/or/directory.c')
-rw-r--r--src/or/directory.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/or/directory.c b/src/or/directory.c
index 66b09eb0d8..d07f04532e 100644
--- a/src/or/directory.c
+++ b/src/or/directory.c
@@ -614,7 +614,7 @@ connection_dir_client_reached_eof(connection_t *conn)
tor_free(body); tor_free(headers);
return -1;
}
- if (router_load_routerlist_from_directory(body, NULL, 1) < 0) {
+ if (router_load_routerlist_from_directory(body, NULL, 1, 0) < 0) {
log_fn(LOG_WARN,"I failed to parse the directory I fetched from %s:%d. Ignoring.", conn->address, conn->port);
} else {
log_fn(LOG_INFO,"updated routers.");
@@ -633,7 +633,7 @@ connection_dir_client_reached_eof(connection_t *conn)
tor_free(body); tor_free(headers);
return -1;
}
- if (!(rrs = router_parse_runningrouters(body))) {
+ if (!(rrs = router_parse_runningrouters(body, 1))) {
log_fn(LOG_WARN, "Can't parse runningrouters list (server '%s')", conn->address);
tor_free(body); tor_free(headers);
return -1;