mirror of https://github.com/fafhrd91/actix-web
Merge branch 'master' into dependabot/cargo/tokio-uring-0.5
This commit is contained in:
commit
f4edafbe7b
|
@ -3,7 +3,7 @@
|
||||||
use std::{error::Error as StdError, fmt, io, str::Utf8Error, string::FromUtf8Error};
|
use std::{error::Error as StdError, fmt, io, str::Utf8Error, string::FromUtf8Error};
|
||||||
|
|
||||||
use derive_more::{Display, Error, From};
|
use derive_more::{Display, Error, From};
|
||||||
pub use http::Error as HttpError;
|
pub use http::{status::InvalidStatusCode, Error as HttpError};
|
||||||
use http::{uri::InvalidUri, StatusCode};
|
use http::{uri::InvalidUri, StatusCode};
|
||||||
|
|
||||||
use crate::{body::BoxBody, Response};
|
use crate::{body::BoxBody, Response};
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
## Unreleased
|
## Unreleased
|
||||||
|
|
||||||
|
- Take the encoded buffer when yielding bytes in the response stream rather than splitting the buffer, reducing memory use
|
||||||
- Minimum supported Rust version (MSRV) is now 1.72.
|
- Minimum supported Rust version (MSRV) is now 1.72.
|
||||||
|
|
||||||
## 4.3.0
|
## 4.3.0
|
||||||
|
|
|
@ -710,7 +710,7 @@ where
|
||||||
}
|
}
|
||||||
|
|
||||||
if !this.buf.is_empty() {
|
if !this.buf.is_empty() {
|
||||||
Poll::Ready(Some(Ok(this.buf.split().freeze())))
|
Poll::Ready(Some(Ok(std::mem::take(&mut this.buf).freeze())))
|
||||||
} else if this.fut.alive() && !this.closed {
|
} else if this.fut.alive() && !this.closed {
|
||||||
Poll::Pending
|
Poll::Pending
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in New Issue