Notify connection on connection window expansion (#86)

When capacity is released back to the connection and a connection level
window update needs to be sent out, the connection task needs to be
notified in order for the send to actually happen.
This commit is contained in:
Carl Lerche
2017-09-14 13:50:52 -07:00
committed by GitHub
parent eaf4192838
commit f84a1bdd1f
2 changed files with 115 additions and 0 deletions

View File

@@ -222,6 +222,12 @@ where
self.flow.assign_capacity(capacity);
stream.recv_flow.assign_capacity(capacity);
if self.flow.unclaimed_capacity().is_some() {
if let Some(task) = task.take() {
task.notify();
}
}
if stream.recv_flow.unclaimed_capacity().is_some() {
// Queue the stream for sending the WINDOW_UPDATE frame.
self.pending_window_updates.push(stream);