Преглед изворни кода

bugfix: we were closing socks-request connections immediately, rather
than flushing them, if they were timing out before we marked them


svn:r1366

Roger Dingledine пре 20 година
родитељ
комит
bcda3ebaef
1 измењених фајлова са 6 додато и 0 уклоњено
  1. 6 0
      src/or/connection.c

+ 6 - 0
src/or/connection.c

@@ -224,6 +224,12 @@ _connection_mark_for_close(connection_t *conn, char reason)
       ;
     }
   conn->marked_for_close = 1;
+
+  /* in case we're going to be held-open-til-flushed, reset
+   * the number of seconds since last successful write, so
+   * we get our whole 15 seconds */
+  conn->timestamp_lastwritten = time(NULL);
+
   return retval;
 }