Prevent connection starvation

When removing a pipe from the lb or fq component,
make sure we do not remove another pipe from the active set.
This commit is contained in:
Martin Hurton
2012-05-31 15:34:30 +02:00
parent 4e7be102f4
commit 2973eaf446
2 changed files with 5 additions and 1 deletions

View File

@@ -58,6 +58,7 @@ void zmq::lb_t::terminated (pipe_t *pipe_)
// accordingly.
if (index < active) {
active--;
pipes.swap (index, active);
if (current == active)
current = 0;
}