Fix behavior of adding a cell to a blocked queue.
commitf89323afdadadb8db7eb48f7cbe75c5f4384dae4
authorNick Mathewson <nickm@torproject.org>
Thu, 2 Sep 2010 19:26:17 +0000 (2 15:26 -0400)
committerNick Mathewson <nickm@torproject.org>
Thu, 2 Sep 2010 19:26:17 +0000 (2 15:26 -0400)
tree55c2743f394ba155a99bbef1b5b6fcb675c930e3
parent9456da17db739aad78633ecb5c1d6c7e8890b0da
Fix behavior of adding a cell to a blocked queue.

We frequently add cells to stream-blocked queues for valid reasons
that don't mean we need to block streams.  The most obvious reason
is if the cell arrives over a circuit rather than from an edge: we
don't block circuits, no matter how full queues get.  The next most
obvious reason is that we allow CONNECTED cells from a newly created
stream to get delivered just fine.

This patch changes the behavior so that we only iterate over the
streams on a circuit when the cell in question came from a stream,
and we only block the stream that generated the cell, so that other
streams can still get their CONNECTEDs in.
src/or/circuitbuild.c
src/or/relay.c
src/or/relay.h