nghttpx: Apply same fix from a225bb2 to spdy upstream

This commit is contained in:
Tatsuhiro Tsujikawa 2014-10-13 21:13:45 +09:00
parent 20de432725
commit 0d4120ce2c
1 changed files with 12 additions and 0 deletions

View File

@ -254,6 +254,18 @@ void SpdyUpstream::maintain_downstream_concurrency()
{
while(get_config()->max_downstream_connections >
downstream_queue_.num_active()) {
if(downstream_queue_.pending_empty()) {
break;
}
{
auto downstream = downstream_queue_.pending_top();
if(downstream->get_request_state() != Downstream::HEADER_COMPLETE &&
downstream->get_request_state() != Downstream::MSG_COMPLETE) {
break;
}
}
auto downstream = downstream_queue_.pop_pending();
if(!downstream) {