If we can't send data for a stream because of its flow control, make sure
not to put it in the send_list, until the flow control lets it send again.
This is specific to 1.9, and should not be backported.
h2s->mws += inc;
if (h2s->mws > 0 && (h2s->flags & H2_SF_BLK_SFCTL)) {
h2s->flags &= ~H2_SF_BLK_SFCTL;
- /* The task will be waken up later */
+ if (h2s->send_wait)
+ LIST_ADDQ(&h2c->send_list, &h2s->list);
+
}
}
else {
if (size <= 0) {
h2s->flags |= H2_SF_BLK_SFCTL;
+ if (h2s->send_wait) {
+ LIST_DEL(&h2s->list);
+ LIST_INIT(&h2s->list);
+ }
goto end;
}