diff options
author | Matt Traudt <sirmatt@ksu.edu> | 2017-09-27 16:11:05 -0400 |
---|---|---|
committer | David Goulet <dgoulet@torproject.org> | 2017-09-29 11:06:31 -0400 |
commit | 3ef7e6f1870bf6bc2c26076c6abb545a576f9a42 (patch) | |
tree | 2b9759e1a993becc1fdbbefe8fa6046e870b6ba9 /changes | |
parent | fc6c0b46fb2741d58e4c8afc22800c76c304b0dc (diff) | |
download | tor-3ef7e6f1870bf6bc2c26076c6abb545a576f9a42.tar.gz tor-3ef7e6f1870bf6bc2c26076c6abb545a576f9a42.zip |
sched: Don't get KIST stuck in an infinite loop
When a channel is scheduled and flush cells returns 0 that is no cells to
flush, we flag it back in waiting for cells so it doesn't get stuck in a
possible infinite loop.
It has been observed on moria1 where a closed channel end up in the scheduler
where the flush process returned 0 cells but it was ultimately kept in the
scheduling loop forever. We suspect that this is due to a more deeper problem
in tor where the channel_more_to_flush() is actually looking at the wrong
queue and was returning 1 for an empty channel thus putting the channel in the
"Case 4" of the scheduler which is to go back in pending state thus
re-considered at the next iteration.
This is a fix that allows the KIST scheduler to recover properly from a not
entirelly diagnosed problem in tor.
Fixes #23676
Signed-off-by: David Goulet <dgoulet@torproject.org>
Diffstat (limited to 'changes')
-rw-r--r-- | changes/bug23676 | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/changes/bug23676 b/changes/bug23676 new file mode 100644 index 0000000000..90f9e31809 --- /dev/null +++ b/changes/bug23676 @@ -0,0 +1,6 @@ + o Major bugfixes (scheduler): + If a channel is put into the scheduler's pending list, then it starts + closing, and then if the scheduler runs before it finishes closing, the + scheduler will get stuck trying to flush its cells while the lower layers + refuse to cooperate. Fix that race condition by given the scheduler an + escape method. Fixes bug 23676; bugfix on 0.3.2.1-alpha |