diff options
author | Nick Mathewson <nickm@torproject.org> | 2020-07-21 15:08:00 -0400 |
---|---|---|
committer | Alexander Færøy <ahf@torproject.org> | 2020-07-29 13:33:35 +0000 |
commit | 3cb9a9b8ce7aeff0931d2b3f57bb2de0ba793669 (patch) | |
tree | bd1fc5e74c78a051d1d9036fdfc786fa65a4c92d /src/core/or | |
parent | e8497bfaa70ef7ce8c48bc2c5464d6fddb8fcff1 (diff) | |
download | tor-3cb9a9b8ce7aeff0931d2b3f57bb2de0ba793669.tar.gz tor-3cb9a9b8ce7aeff0931d2b3f57bb2de0ba793669.zip |
Remove the connection_t.outbuf_flushlen field
This was once used for rate-limiting, but now it's only for
accounting. It hasn't served a useful purpose in a long time.
Closes ticket 33097.
Diffstat (limited to 'src/core/or')
-rw-r--r-- | src/core/or/circuitlist.c | 1 | ||||
-rw-r--r-- | src/core/or/connection_st.h | 2 | ||||
-rw-r--r-- | src/core/or/sendme.c | 2 |
3 files changed, 1 insertions, 4 deletions
diff --git a/src/core/or/circuitlist.c b/src/core/or/circuitlist.c index af98af362a..c0c28c9e2d 100644 --- a/src/core/or/circuitlist.c +++ b/src/core/or/circuitlist.c @@ -2437,7 +2437,6 @@ single_conn_free_bytes(connection_t *conn) if (conn->outbuf) { result += buf_allocation(conn->outbuf); buf_clear(conn->outbuf); - conn->outbuf_flushlen = 0; } if (conn->type == CONN_TYPE_DIR) { dir_connection_t *dir_conn = TO_DIR_CONN(conn); diff --git a/src/core/or/connection_st.h b/src/core/or/connection_st.h index 9cc06d1ef3..f389d21f6f 100644 --- a/src/core/or/connection_st.h +++ b/src/core/or/connection_st.h @@ -98,8 +98,6 @@ struct connection_t { struct buf_t *inbuf; /**< Buffer holding data read over this connection. */ struct buf_t *outbuf; /**< Buffer holding data to write over this * connection. */ - size_t outbuf_flushlen; /**< How much data should we try to flush from the - * outbuf? */ time_t timestamp_last_read_allowed; /**< When was the last time libevent said * we could read? */ time_t timestamp_last_write_allowed; /**< When was the last time libevent diff --git a/src/core/or/sendme.c b/src/core/or/sendme.c index 788f56088c..8ea9ef15d2 100644 --- a/src/core/or/sendme.c +++ b/src/core/or/sendme.c @@ -394,7 +394,7 @@ sendme_connection_edge_consider_sending(edge_connection_t *conn) while (conn->deliver_window <= (STREAMWINDOW_START - STREAMWINDOW_INCREMENT)) { log_debug(log_domain, "Outbuf %" TOR_PRIuSZ ", queuing stream SENDME.", - TO_CONN(conn)->outbuf_flushlen); + buf_datalen(TO_CONN(conn)->outbuf)); conn->deliver_window += STREAMWINDOW_INCREMENT; if (connection_edge_send_command(conn, RELAY_COMMAND_SENDME, NULL, 0) < 0) { |