backport r13583

svn:r13584
This commit is contained in:
Roger Dingledine 2008-02-19 21:38:27 +00:00
parent 839a8a8014
commit a1e8cf5ccb
3 changed files with 13 additions and 0 deletions

View File

@ -7,6 +7,10 @@ Changes in versino 0.1.2.20 - 2008-??-??
blocked_on_or_conn field set. This prevents a rare assertion error
that could occur when an OR connection carrying tunneled directory
requests closed before the requests were complete. Fixes bug 406.
- If we only ever used Tor for hidden service lookups or posts, we
would stop building circuits and start refusing connections after
24 hours, since we falsely believed that Tor was dormant. Reported
by nwf.
o Minor bugfixes:
- Stop recommending that every server operator send mail to tor-ops.

View File

@ -1390,6 +1390,11 @@ connection_ap_handshake_rewrite_and_attach(edge_connection_t *conn,
connection_mark_unattached_ap(conn, END_STREAM_REASON_TORPROTOCOL);
return -1;
}
/* Help predict this next time. We're not sure if it will need
* a stable circuit yet, but we know we'll need *something*. */
rep_hist_note_used_internal(now, 0, 1);
if (r==0) {
conn->_base.state = AP_CONN_STATE_RENDDESC_WAIT;
log_info(LD_REND, "Unknown descriptor %s. Fetching.",

View File

@ -455,6 +455,10 @@ directory_initiate_command(const char *address, uint32_t addr,
* populate it and add it at the right state
* socketpair and hook up both sides
*/
if (private_connection)
rep_hist_note_used_port(time(NULL), conn->_base.port);
conn->dirconn_direct = 0;
conn->_base.s =
connection_ap_make_bridge(conn->_base.address, conn->_base.port,