From aa617cafb8b39fba11a172531b31178c3b24b6c1 Mon Sep 17 00:00:00 2001 From: sorz Date: Tue, 17 Apr 2018 23:32:26 +1000 Subject: [PATCH] Fix regression with Rust 1.26 rust-lang/rust#49945 --- src/proxy/http.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/proxy/http.rs b/src/proxy/http.rs index c52e225..fd0f66f 100644 --- a/src/proxy/http.rs +++ b/src/proxy/http.rs @@ -51,7 +51,7 @@ where T: AsRef<[u8]> + 'static { Ok(future::Loop::Continue((reader, buf))) }) }; - let skip = response.and_then(|(reader, buf)| { + let skip = response.and_then(move |(reader, buf)| { let reader = reader.take(8 * 1024); future::loop_fn((reader, buf), skip_headers) .map(|reader| reader.into_inner())