aboutsummaryrefslogtreecommitdiff
path: root/src/or/relay.c
diff options
context:
space:
mode:
authorAndrea Shepard <andrea@torproject.org>2013-08-25 08:45:07 -0700
committerAndrea Shepard <andrea@torproject.org>2014-09-30 22:48:24 -0700
commitd438cf1ec9d5de08b8a8fffd7c38b66134fd337c (patch)
tree0ce78e25fde753880ff5bf092c1599d982d0c8a5 /src/or/relay.c
parent1987157d0c1e9acb0b88156e7104fbc8a11c5932 (diff)
downloadtor-d438cf1ec9d5de08b8a8fffd7c38b66134fd337c.tar.gz
tor-d438cf1ec9d5de08b8a8fffd7c38b66134fd337c.zip
Implement scheduler mechanism to track lists of channels wanting cells or writes; doesn't actually drive the cell flow from it yet
Diffstat (limited to 'src/or/relay.c')
-rw-r--r--src/or/relay.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/or/relay.c b/src/or/relay.c
index d97c84fb07..2c16e4acca 100644
--- a/src/or/relay.c
+++ b/src/or/relay.c
@@ -39,6 +39,7 @@
#include "router.h"
#include "routerlist.h"
#include "routerparse.h"
+#include "scheduler.h"
static edge_connection_t *relay_lookup_conn(circuit_t *circ, cell_t *cell,
cell_direction_t cell_direction,
@@ -2868,6 +2869,10 @@ append_cell_to_circuit_queue(circuit_t *circ, channel_t *chan,
log_debug(LD_GENERAL, "Made a circuit active.");
}
+ /* New way: mark this as having waiting cells for the scheduler */
+ scheduler_channel_has_waiting_cells(chan);
+
+ /* TODO remove this once scheduler does it */
if (!channel_has_queued_writes(chan)) {
/* There is no data at all waiting to be sent on the outbuf. Add a
* cell, so that we can notice when it gets flushed, flushed_some can