summaryrefslogtreecommitdiff
path: root/src/or/main.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2010-09-08 10:28:41 -0400
committerNick Mathewson <nickm@torproject.org>2010-09-08 10:28:41 -0400
commit669fd05ed8cf7b90bb9e43dbbbbd35f40bf05fa0 (patch)
treea0f88ac2f0b80a8e6d510664aa8ff284054ab6eb /src/or/main.c
parentedc9256e95e307092d57cf273ac699f33cb0192b (diff)
parent2bc82324d5051e5233a9332dd5958d5ca60c2931 (diff)
downloadtor-669fd05ed8cf7b90bb9e43dbbbbd35f40bf05fa0.tar.gz
tor-669fd05ed8cf7b90bb9e43dbbbbd35f40bf05fa0.zip
Merge remote branch 'origin/maint-0.2.1'
Diffstat (limited to 'src/or/main.c')
-rw-r--r--src/or/main.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/or/main.c b/src/or/main.c
index 2d75a58088..f33dc2f6b4 100644
--- a/src/or/main.c
+++ b/src/or/main.c
@@ -791,12 +791,13 @@ run_connection_housekeeping(int i, time_t now)
"Tor gave up on the connection");
connection_mark_for_close(conn);
conn->hold_open_until_flushed = 1;
- } else if (past_keepalive && !connection_state_is_open(conn)) {
- /* We never managed to actually get this connection open and happy. */
- log_info(LD_OR,"Expiring non-open OR connection to fd %d (%s:%d).",
- conn->s,conn->address, conn->port);
- connection_mark_for_close(conn);
- conn->hold_open_until_flushed = 1;
+ } else if (!connection_state_is_open(conn)) {
+ if (past_keepalive) {
+ /* We never managed to actually get this connection open and happy. */
+ log_info(LD_OR,"Expiring non-open OR connection to fd %d (%s:%d).",
+ conn->s,conn->address, conn->port);
+ connection_mark_for_close(conn);
+ }
} else if (we_are_hibernating() && !or_conn->n_circuits &&
!buf_datalen(conn->outbuf)) {
/* We're hibernating, there's no circuits, and nothing to flush.*/