[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[or-cvs] when we"re giving up on a circuit and retrying on a new one,
Update of /home2/or/cvsroot/tor/src/or
In directory moria:/home/arma/work/onion/cvs/tor/src/or
Modified Files:
connection_edge.c
Log Message:
when we're giving up on a circuit and retrying on a new one,
log the name of the exit node. perhaps people will find this
useful, or see patterns, or something.
Index: connection_edge.c
===================================================================
RCS file: /home2/or/cvsroot/tor/src/or/connection_edge.c,v
retrieving revision 1.369
retrieving revision 1.370
diff -u -d -r1.369 -r1.370
--- connection_edge.c 5 Dec 2005 06:16:24 -0000 1.369
+++ connection_edge.c 6 Dec 2005 07:21:17 -0000 1.370
@@ -314,6 +314,7 @@
connection_t **carray;
connection_t *conn;
circuit_t *circ;
+ const char *nickname;
int n, i;
time_t now = time(NULL);
or_options_t *options = get_options();
@@ -355,9 +356,11 @@
continue;
}
tor_assert(circ->purpose == CIRCUIT_PURPOSE_C_GENERAL);
- notice(LD_APP,"We tried for %d seconds to connect to '%s'. Retrying on a new circuit.",
+ nickname = build_state_get_exit_nickname(circ->build_state);
+ notice(LD_APP,"We tried for %d seconds to connect to '%s' using exit '%s'. Retrying on a new circuit.",
(int)(now - conn->timestamp_lastread),
- safe_str(conn->socks_request->address));
+ safe_str(conn->socks_request->address),
+ nickname ? nickname : "*unnamed*");
/* send an end down the circuit */
connection_edge_end(conn, END_STREAM_REASON_TIMEOUT, conn->cpath_layer);
/* un-mark it as ending, since we're going to reuse it */