summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoger Dingledine <arma@torproject.org>2008-06-13 04:07:29 +0000
committerRoger Dingledine <arma@torproject.org>2008-06-13 04:07:29 +0000
commitb3947f4e98fe5ac9d4767a2c81b3f4372bafd683 (patch)
tree70f2a18dd1ace8cb2b0f2ea9f55e667ed4735d9a
parente649a72d9c7c2889cd10b5640a26b4148a6d5826 (diff)
downloadtor-b3947f4e98fe5ac9d4767a2c81b3f4372bafd683.tar.gz
tor-b3947f4e98fe5ac9d4767a2c81b3f4372bafd683.zip
backport r14998
svn:r15180
-rw-r--r--src/or/circuitbuild.c8
-rw-r--r--src/or/routerlist.c8
2 files changed, 7 insertions, 9 deletions
diff --git a/src/or/circuitbuild.c b/src/or/circuitbuild.c
index f3046b75aa..b403fc2ed9 100644
--- a/src/or/circuitbuild.c
+++ b/src/or/circuitbuild.c
@@ -1045,11 +1045,11 @@ new_route_len(uint8_t purpose, extend_info_t *exit,
purpose != CIRCUIT_PURPOSE_S_ESTABLISH_INTRO)
routelen++;
- log_debug(LD_CIRC,"Chosen route length %d (%d routers available).",
- routelen, smartlist_len(routers));
-
num_acceptable_routers = count_acceptable_routers(routers);
+ log_debug(LD_CIRC,"Chosen route length %d (%d/%d routers available).",
+ routelen, num_acceptable_routers, smartlist_len(routers));
+
if (num_acceptable_routers < 2) {
log_info(LD_CIRC,
"Not enough acceptable routers (%d). Discarding this circuit.",
@@ -1961,7 +1961,7 @@ log_entry_guards(int severity)
{
tor_snprintf(buf, sizeof(buf), "%s (%s%s)",
e->nickname,
- e->bad_since ? "down " : "up ",
+ entry_is_live(e, 0, 1, 0) ? "up " : "down ",
e->made_contact ? "made-contact" : "never-contacted");
smartlist_add(elements, tor_strdup(buf));
});
diff --git a/src/or/routerlist.c b/src/or/routerlist.c
index 83d36d351c..72f5a8d896 100644
--- a/src/or/routerlist.c
+++ b/src/or/routerlist.c
@@ -2683,8 +2683,8 @@ router_set_status(const char *digest, int up)
router = router_get_by_digest(digest);
if (router) {
- log_debug(LD_DIR,"Marking router '%s' as %s.",
- router->nickname, up ? "up" : "down");
+ log_debug(LD_DIR,"Marking router '%s/%s' as %s.",
+ router->nickname, router->address, up ? "up" : "down");
if (!up && router_is_me(router) && !we_are_hibernating())
log_warn(LD_NET, "We just marked ourself as down. Are your external "
"addresses reachable?");
@@ -4189,9 +4189,7 @@ update_router_have_minimum_dir_info(void)
}
if (!res && have_min_dir_info) {
log(LOG_NOTICE, LD_DIR,"Our directory information is no longer up-to-date "
- "enough to build circuits.%s",
- num_usable > 2 ? "" : " (Not enough servers seem reachable -- "
- "is your network connection down?)");
+ "enough to build circuits: %s", dir_info_status);
control_event_client_status(LOG_NOTICE, "NOT_ENOUGH_DIR_INFO");
}
have_min_dir_info = res;