diff options
author | Robert Ransom <rransom.8774@gmail.com> | 2011-12-24 04:47:30 -0800 |
---|---|---|
committer | Robert Ransom <rransom.8774@gmail.com> | 2011-12-27 08:02:43 -0800 |
commit | f88c8ca8c98dc3a0c9e63012ce425d1287625444 (patch) | |
tree | b61d52edad8fec8dc045ddd53e2bc49b6f0666bf /src/or/circuituse.c | |
parent | 078e3e9dd59520b7f40a126a91e89eba91098c49 (diff) | |
download | tor-f88c8ca8c98dc3a0c9e63012ce425d1287625444.tar.gz tor-f88c8ca8c98dc3a0c9e63012ce425d1287625444.zip |
Don't close HS service-side rend circs on timeout
Diffstat (limited to 'src/or/circuituse.c')
-rw-r--r-- | src/or/circuituse.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/or/circuituse.c b/src/or/circuituse.c index d9d95bc68a..9778ae7b29 100644 --- a/src/or/circuituse.c +++ b/src/or/circuituse.c @@ -550,6 +550,22 @@ circuit_expire_building(void) } } + /* If this is a service-side rendezvous circuit which is far + * enough along in connecting to its destination, consider sparing + * it. */ + if (!(TO_ORIGIN_CIRCUIT(victim)->hs_circ_has_timed_out) && + victim->purpose == CIRCUIT_PURPOSE_S_CONNECT_REND) { + log_info(LD_CIRC,"Marking circ %s:%d:%d (state %d:%s, purpose %d) " + "as timed-out HS circ; relaunching rendezvous attempt.", + victim->n_conn->_base.address, victim->n_conn->_base.port, + victim->n_circ_id, + victim->state, circuit_state_to_string(victim->state), + victim->purpose); + TO_ORIGIN_CIRCUIT(victim)->hs_circ_has_timed_out = 1; + rend_service_relaunch_rendezvous(TO_ORIGIN_CIRCUIT(victim)); + continue; + } + if (victim->n_conn) log_info(LD_CIRC,"Abandoning circ %s:%d:%d (state %d:%s, purpose %d)", victim->n_conn->_base.address, victim->n_conn->_base.port, |