mirror of
https://github.com/actix/actix-extras.git
synced 2024-11-24 07:53:00 +01:00
HttpServer not sending streamed request body on HTTP/2 requests #544
This commit is contained in:
parent
63a443fce0
commit
dd948f836e
@ -1,10 +1,13 @@
|
|||||||
# Changes
|
# Changes
|
||||||
|
|
||||||
## [0.7.13] - 2018-10-*
|
## [0.7.13] - 2018-10-14
|
||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
|
|
||||||
* Fixed rustls build
|
* Fixed rustls support
|
||||||
|
|
||||||
|
* HttpServer not sending streamed request body on HTTP/2 requests #544
|
||||||
|
|
||||||
|
|
||||||
## [0.7.12] - 2018-10-10
|
## [0.7.12] - 2018-10-10
|
||||||
|
|
||||||
|
@ -216,7 +216,7 @@ impl<S> HttpRequest<S> {
|
|||||||
self.url_for(name, &NO_PARAMS)
|
self.url_for(name, &NO_PARAMS)
|
||||||
}
|
}
|
||||||
|
|
||||||
/// This method returns reference to current `RouteInfo` object.
|
/// This method returns reference to current `ResourceInfo` object.
|
||||||
#[inline]
|
#[inline]
|
||||||
pub fn resource(&self) -> &ResourceInfo {
|
pub fn resource(&self) -> &ResourceInfo {
|
||||||
&self.resource
|
&self.resource
|
||||||
|
@ -299,12 +299,11 @@ impl Output {
|
|||||||
match resp.chunked() {
|
match resp.chunked() {
|
||||||
Some(true) => {
|
Some(true) => {
|
||||||
// Enable transfer encoding
|
// Enable transfer encoding
|
||||||
if version == Version::HTTP_2 {
|
|
||||||
info.length = ResponseLength::None;
|
|
||||||
TransferEncoding::eof(buf)
|
|
||||||
} else {
|
|
||||||
info.length = ResponseLength::Chunked;
|
info.length = ResponseLength::Chunked;
|
||||||
|
if version == Version::HTTP_11 {
|
||||||
TransferEncoding::chunked(buf)
|
TransferEncoding::chunked(buf)
|
||||||
|
} else {
|
||||||
|
TransferEncoding::eof(buf)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Some(false) => TransferEncoding::eof(buf),
|
Some(false) => TransferEncoding::eof(buf),
|
||||||
@ -337,20 +336,16 @@ impl Output {
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// Enable transfer encoding
|
// Enable transfer encoding
|
||||||
match version {
|
|
||||||
Version::HTTP_11 => {
|
|
||||||
info.length = ResponseLength::Chunked;
|
info.length = ResponseLength::Chunked;
|
||||||
|
if version == Version::HTTP_11 {
|
||||||
TransferEncoding::chunked(buf)
|
TransferEncoding::chunked(buf)
|
||||||
}
|
} else {
|
||||||
_ => {
|
|
||||||
info.length = ResponseLength::None;
|
|
||||||
TransferEncoding::eof(buf)
|
TransferEncoding::eof(buf)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
pub(crate) enum ContentEncoder {
|
pub(crate) enum ContentEncoder {
|
||||||
|
Loading…
Reference in New Issue
Block a user