more clean up
This commit is contained in:
+1
-1
@@ -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,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>> {
|
||||
|
||||
@@ -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;
|
||||
|
||||
|
||||
@@ -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)) {
|
||||
|
||||
Reference in New Issue
Block a user