Downgrade a few INFO level logs to DEBUG again. Also add two or three new

logs in cases where a calling function's log was downgraded and we wouldn't
get any log message otherwise.


svn:r5263
This commit is contained in:
Peter Palfrader
2005-10-17 16:21:42 +00:00
parent bec2271029
commit 0d9aedfcea
10 changed files with 22 additions and 15 deletions
+1 -1
View File
@@ -283,7 +283,7 @@ command_process_relay_cell(cell_t *cell, connection_t *conn)
circ = circuit_get_by_circid_orconn(cell->circ_id, conn);
if (!circ) {
log_fn(LOG_INFO,"unknown circuit %d on connection from %s:%d. Dropping.",
log_fn(LOG_DEBUG,"unknown circuit %d on connection from %s:%d. Dropping.",
cell->circ_id, conn->address, conn->port);
return;
}
+1 -1
View File
@@ -1209,7 +1209,7 @@ connection_read_to_buf(connection_t *conn, int *max_to_read)
conn->nickname ? conn->nickname : "not set", conn->address);
return -1;
case TOR_TLS_ERROR:
log_fn(LOG_INFO,"tls error. breaking (nickname %s, address %s).",
log_fn(LOG_DEBUG,"tls error. breaking (nickname %s, address %s).",
conn->nickname ? conn->nickname : "not set", conn->address);
return -1;
case TOR_TLS_WANTWRITE:
+1 -1
View File
@@ -172,7 +172,7 @@ connection_or_finished_connecting(connection_t *conn)
tor_assert(conn->type == CONN_TYPE_OR);
tor_assert(conn->state == OR_CONN_STATE_CONNECTING);
log_fn(LOG_INFO,"OR connect() to router at %s:%u finished.",
log_fn(LOG_DEBUG,"OR connect() to router at %s:%u finished.",
conn->address,conn->port);
if (get_options()->HttpsProxy) {
+2 -2
View File
@@ -163,7 +163,7 @@ connection_cpu_process_inbuf(connection_t *conn)
circ = circuit_get_by_circid_orconn(circ_id, p_conn);
if (success == 0) {
log_fn(LOG_INFO,"decoding onionskin failed. Closing.");
log_fn(LOG_DEBUG,"decoding onionskin failed. Closing.");
if (circ)
circuit_mark_for_close(circ);
goto done_processing;
@@ -266,7 +266,7 @@ cpuworker_main(void *data)
if (onion_skin_server_handshake(question, onion_key, last_onion_key,
reply_to_proxy, keys, CPATH_KEY_MATERIAL_LEN) < 0) {
/* failure */
log_fn(LOG_INFO,"onion_skin_server_handshake failed.");
log_fn(LOG_DEBUG,"onion_skin_server_handshake failed.");
memset(buf,0,LEN_ONION_RESPONSE); /* send all zeros for failure */
} else {
/* success */
+2 -2
View File
@@ -844,7 +844,7 @@ connection_dir_client_reached_eof(connection_t *conn)
abs(delta)/60, delta>0 ? "behind" : "ahead");
skewed = 1; /* don't check the recommended-versions line */
} else {
log_fn(LOG_INFO, "Time on received directory is within tolerance; we are %d seconds skewed. (That's okay.)", delta);
log_fn(LOG_DEBUG, "Time on received directory is within tolerance; we are %d seconds skewed. (That's okay.)", delta);
}
}
@@ -1576,7 +1576,7 @@ connection_dir_finished_connecting(connection_t *conn)
tor_assert(conn->type == CONN_TYPE_DIR);
tor_assert(conn->state == DIR_CONN_STATE_CONNECTING);
log_fn(LOG_INFO,"Dir connection to router %s:%u established.",
log_fn(LOG_DEBUG,"Dir connection to router %s:%u established.",
conn->address,conn->port);
conn->state = DIR_CONN_STATE_CLIENT_SENDING; /* start flushing conn */
+2 -1
View File
@@ -1039,7 +1039,8 @@ dirserv_regenerate_directory(void)
return -1;
}
set_cached_dir(&the_directory, new_directory, time(NULL));
log_fn(LOG_INFO,"New directory (size %d):\n%s",(int)the_directory.dir_len,
log_fn(LOG_INFO,"New directory (size %d) has been built.",(int)the_directory.dir_len);
log_fn(LOG_DEBUG,"New directory (size %d):\n%s",(int)the_directory.dir_len,
the_directory.dir);
the_directory_is_dirty = 0;
+6 -2
View File
@@ -245,8 +245,10 @@ onion_skin_server_handshake(const char *onion_skin, /* ONIONSKIN_CHALLENGE_LEN b
}
dh = crypto_dh_new();
if (crypto_dh_get_public(dh, handshake_reply_out, DH_KEY_LEN))
if (crypto_dh_get_public(dh, handshake_reply_out, DH_KEY_LEN)) {
log_fn(LOG_INFO, "crypto_dh_get_public failed.");
goto err;
}
#ifdef DEBUG_ONION_SKINS
printf("Server: server g^y:");
@@ -259,8 +261,10 @@ onion_skin_server_handshake(const char *onion_skin, /* ONIONSKIN_CHALLENGE_LEN b
key_material = tor_malloc(DIGEST_LEN+key_out_len);
len = crypto_dh_compute_secret(dh, challenge, DH_KEY_LEN,
key_material, DIGEST_LEN+key_out_len);
if (len < 0)
if (len < 0) {
log_fn(LOG_INFO, "crypto_dh_compute_secret failed.");
goto err;
}
/* send back H(K|0) as proof that we learned K. */
memcpy(handshake_reply_out+DH_KEY_LEN, key_material, DIGEST_LEN);
+1 -1
View File
@@ -629,7 +629,7 @@ router_retry_connections(int force)
if (force ||
!connection_get_by_identity_digest(router->identity_digest,
CONN_TYPE_OR)) {
log_fn(LOG_INFO,"%sconnecting to %s at %s:%u.",
log_fn(LOG_DEBUG,"%sconnecting to %s at %s:%u.",
clique_mode(options) ? "(forced) " : "",
router->nickname, router->address, router->or_port);
/* Remember when we started trying to determine reachability */