mirror of
https://github.com/actix/actix-web.git
synced 2024-11-27 12:01:15 +00:00
fix compression
This commit is contained in:
parent
18f3841783
commit
c35d294611
1 changed files with 2 additions and 1 deletions
|
@ -394,7 +394,8 @@ impl PayloadEncoder {
|
|||
},
|
||||
Body::Binary(ref mut bytes) => {
|
||||
if compression {
|
||||
let transfer = TransferEncoding::eof(SharedBytes::default());
|
||||
let mut buf = SharedBytes::default();
|
||||
let transfer = TransferEncoding::eof(buf.clone());
|
||||
let mut enc = match encoding {
|
||||
ContentEncoding::Deflate => ContentEncoder::Deflate(
|
||||
DeflateEncoder::new(transfer, Compression::Default)),
|
||||
|
|
Loading…
Reference in a new issue