1
0
mirror of https://github.com/fafhrd91/actix-web synced 2025-08-28 07:47:49 +02:00

flush is useless

This commit is contained in:
Nikolay Kim
2018-01-14 19:28:34 -08:00
parent 89a89e7b18
commit a7c24aace1
6 changed files with 14 additions and 39 deletions

View File

@@ -575,16 +575,6 @@ impl<S: 'static, H> ProcessResponse<S, H> {
if self.running == RunningState::Paused || self.drain.is_some() {
match io.poll_completed(false) {
Ok(Async::Ready(_)) => {
match io.flush() {
Ok(Async::Ready(_)) => (),
Ok(Async::NotReady) => return Err(PipelineState::Response(self)),
Err(err) => {
debug!("Error sending data: {}", err);
info.error = Some(err.into());
return Ok(FinishingMiddlewares::init(info, self.resp))
}
}
self.running.resume();
// resolve drain futures