diff options
author | Roger Dingledine <arma@torproject.org> | 2006-03-21 23:27:43 +0000 |
---|---|---|
committer | Roger Dingledine <arma@torproject.org> | 2006-03-21 23:27:43 +0000 |
commit | 28fafb9022930e29658093c0670f670037ae28b6 (patch) | |
tree | 7c4d62b918001de817e82f0bbf3bf2115b03e7fa /src/or/circuituse.c | |
parent | 5399e394a83907fb2e4f06ea6c37cbb9a8f9cb45 (diff) | |
download | tor-28fafb9022930e29658093c0670f670037ae28b6.tar.gz tor-28fafb9022930e29658093c0670f670037ae28b6.zip |
new config option SocksTimeout: How long do we let a socks connection
wait unattached before we fail it?
Use this value for controller socks timeout, for normal socks
timeout, and for hidden-service socks timeout.
svn:r6217
Diffstat (limited to 'src/or/circuituse.c')
-rw-r--r-- | src/or/circuituse.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/or/circuituse.c b/src/or/circuituse.c index e808a31825..e8acffa40f 100644 --- a/src/or/circuituse.c +++ b/src/or/circuituse.c @@ -13,9 +13,6 @@ const char circuituse_c_id[] = #include "or.h" -/** Longest time to wait for a circuit before closing an AP connection */ -#define CONN_AP_MAX_ATTACH_DELAY 59 - /********* START VARIABLES **********/ extern circuit_t *global_circuitlist; /* from circuitlist.c */ @@ -1154,7 +1151,7 @@ connection_ap_handshake_attach_circuit(connection_t *conn) tor_assert(conn->socks_request); conn_age = time(NULL) - conn->timestamp_created; - if (conn_age > CONN_AP_MAX_ATTACH_DELAY) { + if (conn_age > get_options()->SocksTimeout) { log_notice(LD_APP, "Tried for %d seconds to get a connection to %s:%d. Giving up.", conn_age, safe_str(conn->socks_request->address), |