Skip to content
Permalink

Comparing changes

This is a direct comparison between two commits made in this repository or its related repositories. View the default comparison for this range or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: http-rs/async-h1
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 8d7aba4d581a6d2e697b6dc5113d5a8a2b5c294f
Choose a base ref
..
head repository: http-rs/async-h1
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: ab1daa95fb020965648bdcc8bff38ce6d53bbc91
Choose a head ref
Showing with 194 additions and 446 deletions.
  1. +1 −3 Cargo.toml
  2. +190 −440 src/chunked/decoder.rs
  3. +1 −1 src/server/decode.rs
  4. +1 −1 src/server/mod.rs
  5. +1 −1 tests/client_decode.rs
4 changes: 1 addition & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "async-h1"
version = "2.3.2"
version = "2.3.3"
license = "MIT OR Apache-2.0"
repository = "https://github.com/http-rs/async-h1"
documentation = "https://docs.rs/async-h1"
@@ -21,8 +21,6 @@ edition = "2018"
httparse = "1.3.4"
async-std = "1.7.0"
http-types = { version = "2.9.0", default-features = false }
byte-pool = "0.2.2"
lazy_static = "1.4.0"
futures-core = "0.3.8"
log = "0.4.11"
pin-project = "1.0.2"
630 changes: 190 additions & 440 deletions src/chunked/decoder.rs

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/server/decode.rs
Original file line number Diff line number Diff line change
@@ -127,7 +127,7 @@ where
let reader = ReadNotifier::new(reader, body_read_sender);
let reader = BufReader::new(reader);
req.set_body(Body::from_reader(reader, None));
return Ok(Some((req, BodyReader::Chunked(reader_clone))));
Ok(Some((req, BodyReader::Chunked(reader_clone))))
} else if let Some(len) = content_length {
let len = len.len();
let reader = Arc::new(Mutex::new(reader.take(len)));
2 changes: 1 addition & 1 deletion src/server/mod.rs
Original file line number Diff line number Diff line change
@@ -187,7 +187,7 @@ where

if let Some(upgrade_sender) = upgrade_sender {
upgrade_sender.send(Connection::new(self.io.clone())).await;
return Ok(ConnectionStatus::Close);
Ok(ConnectionStatus::Close)
} else if close_connection {
Ok(ConnectionStatus::Close)
} else {
2 changes: 1 addition & 1 deletion tests/client_decode.rs
Original file line number Diff line number Diff line change
@@ -26,7 +26,7 @@ mod client_decode {
])
.await?;

assert_eq!(res.header(&headers::DATE).is_some(), true);
assert!(res.header(&headers::DATE).is_some());
Ok(())
}