mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
partially integrate streaming request bodies with http re-direct
This commit is contained in:
parent
ad4dea7d84
commit
c1b76533fa
6 changed files with 132 additions and 44 deletions
|
@ -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
|
||||
};
|
||||
|
|
|
@ -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]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue