more clean up

This commit is contained in:
Lucio Franco
2019-08-18 01:30:26 -04:00
parent b2a9ab97d7
commit ef87a558e7
12 changed files with 36 additions and 33 deletions
+1 -1
View File
@@ -14,7 +14,7 @@ tower-service = { git = "http://github.com/tower-rs/tower", branch = "std-future
tower-util = { git = "http://github.com/tower-rs/tower", branch = "std-future" }
h2 = { git = "https://github.com/LucioFranco/h2", branch = "lucio/tower-h2-hack" }
http = "0.1"
http-body = { git = "https://github.com/hyperium/http-body", branch = "lucio/pin" }
http-body = { git = "https://github.com/hyperium/http-body" }
log = "0.4"
[dev-dependencies]
+1 -1
View File
@@ -1,10 +1,10 @@
#![feature(async_await)]
use http::Request;
use std::pin::Pin;
use std::task::{Context, Poll};
use tokio::net::TcpStream;
use tower_h2::Connection;
use std::pin::Pin;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
+1 -1
View File
@@ -2,9 +2,9 @@
use futures_util::future;
use http::{Request, Response};
use std::pin::Pin;
use std::task::{Context, Poll};
use tokio::net::TcpListener;
use std::pin::Pin;
use tower_h2::{RecvBody, Server};
use tower_service::Service;
-1
View File
@@ -90,7 +90,6 @@ where
self.h2.reserve_capacity(1);
if self.h2.capacity() == 0 {
// TODO: The loop should not be needed once
// carllerche/h2#270 is fixed.
loop {
match ready!(self.h2.poll_capacity(cx)) {