diff options
author | Gregory Terzian <gterzian@users.noreply.github.com> | 2020-05-31 12:00:55 +0800 |
---|---|---|
committer | Gregory Terzian <gterzian@users.noreply.github.com> | 2020-06-04 11:38:38 +0800 |
commit | c1b76533fa5c36abc894e84c2b2746fca7afe2e1 (patch) | |
tree | 6402ffda327eb5f596db52c1da88853c349d4c46 /components/net | |
parent | ad4dea7d84bc94c6d31f4ac4f7f7bd8aae895a8f (diff) | |
download | servo-c1b76533fa5c36abc894e84c2b2746fca7afe2e1.tar.gz servo-c1b76533fa5c36abc894e84c2b2746fca7afe2e1.zip |
partially integrate streaming request bodies with http re-direct
Diffstat (limited to 'components/net')
-rw-r--r-- | components/net/http_loader.rs | 3 | ||||
-rw-r--r-- | components/net/tests/http_loader.rs | 6 |
2 files changed, 2 insertions, 7 deletions
diff --git a/components/net/http_loader.rs b/components/net/http_loader.rs index df851ce51c3..44b36c1bb4d 100644 --- a/components/net/http_loader.rs +++ b/components/net/http_loader.rs @@ -973,8 +973,7 @@ fn http_network_or_cache_fetch( let http_request = if request_has_no_window && request.redirect_mode == RedirectMode::Error { request } else { - // Step 5.2 - // TODO Implement body source + // Step 5.2.1, .2.2 and .2.3 and 2.4 http_request = request.clone(); &mut http_request }; diff --git a/components/net/tests/http_loader.rs b/components/net/tests/http_loader.rs index 1e4f0782ffa..0e4c401d3dc 100644 --- a/components/net/tests/http_loader.rs +++ b/components/net/tests/http_loader.rs @@ -113,11 +113,7 @@ fn create_request_body_with_content(content: Vec<u8>) -> RequestBody { }), ); - RequestBody { - stream: Some(chunk_request_sender), - source: BodySource::USVString, - total_bytes: Some(content_len), - } + RequestBody::new(chunk_request_sender, BodySource::Object, Some(content_len)) } #[test] |