aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Cargo.lock6
-rw-r--r--components/net/Cargo.toml2
-rw-r--r--components/net/http_loader.rs2
-rw-r--r--components/net/tests/http_loader.rs4
4 files changed, 7 insertions, 7 deletions
diff --git a/Cargo.lock b/Cargo.lock
index ef61e01670f..866367505c1 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -879,7 +879,7 @@ dependencies = [
[[package]]
name = "flate2"
-version = "0.2.19"
+version = "1.0.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"libc 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1814,7 +1814,7 @@ dependencies = [
"brotli 1.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
"cookie 0.10.1 (registry+https://github.com/rust-lang/crates.io-index)",
"devtools_traits 0.0.1",
- "flate2 0.2.19 (registry+https://github.com/rust-lang/crates.io-index)",
+ "flate2 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.10.13 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper-openssl 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper_serde 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -3652,7 +3652,7 @@ dependencies = [
"checksum error-chain 0.10.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d9435d864e017c3c6afeac1654189b06cdb491cf2ff73dbf0d73b0f292f42ff8"
"checksum euclid 0.17.0 (registry+https://github.com/rust-lang/crates.io-index)" = "b2744c002882c67d0f6d6e8cfdf16eae729dc27744d312745132e62218b7de5c"
"checksum expat-sys 2.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "c470ccb972f2088549b023db8029ed9da9426f5affbf9b62efff7009ab8ed5b1"
-"checksum flate2 0.2.19 (registry+https://github.com/rust-lang/crates.io-index)" = "36df0166e856739905cd3d7e0b210fe818592211a008862599845e012d8d304c"
+"checksum flate2 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "9fac2277e84e5e858483756647a9d0aa8d9a2b7cba517fd84325a0aaa69a0909"
"checksum fnv 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)" = "6cc484842f1e2884faf56f529f960cc12ad8c71ce96cc7abba0a067c98fee344"
"checksum fontsan 0.4.0 (git+https://github.com/servo/fontsan)" = "<none>"
"checksum foreign-types 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1"
diff --git a/components/net/Cargo.toml b/components/net/Cargo.toml
index da9a2c7393a..4329215010a 100644
--- a/components/net/Cargo.toml
+++ b/components/net/Cargo.toml
@@ -16,7 +16,7 @@ base64 = "0.6"
brotli = "1.0.6"
cookie = "0.10"
devtools_traits = {path = "../devtools_traits"}
-flate2 = "0.2.0"
+flate2 = "1"
hyper = "0.10"
hyper_serde = "0.8"
hyper-openssl = "0.2.2"
diff --git a/components/net/http_loader.rs b/components/net/http_loader.rs
index ea9e1b129d9..c1a8215b06f 100644
--- a/components/net/http_loader.rs
+++ b/components/net/http_loader.rs
@@ -290,7 +290,7 @@ impl StreamedResponse {
let decoder = {
if let Some(ref encoding) = response.headers.get::<ContentEncoding>().cloned() {
if encoding.contains(&Encoding::Gzip) {
- Decoder::Gzip(GzDecoder::new(response)?)
+ Decoder::Gzip(GzDecoder::new(response))
}
else if encoding.contains(&Encoding::Deflate) {
Decoder::Deflate(DeflateDecoder::new(response))
diff --git a/components/net/tests/http_loader.rs b/components/net/tests/http_loader.rs
index b9a84e6d0c3..67e8f9456e9 100644
--- a/components/net/tests/http_loader.rs
+++ b/components/net/tests/http_loader.rs
@@ -394,7 +394,7 @@ fn test_load_when_redirecting_from_a_post_should_rewrite_next_request_as_get() {
fn test_load_should_decode_the_response_as_deflate_when_response_headers_have_content_encoding_deflate() {
let handler = move |_: HyperRequest, mut response: HyperResponse| {
response.headers_mut().set(ContentEncoding(vec![Encoding::Deflate]));
- let mut e = DeflateEncoder::new(Vec::new(), Compression::Default);
+ let mut e = DeflateEncoder::new(Vec::new(), Compression::default());
e.write(b"Yay!").unwrap();
let encoded_content = e.finish().unwrap();
response.send(&encoded_content).unwrap();
@@ -424,7 +424,7 @@ fn test_load_should_decode_the_response_as_deflate_when_response_headers_have_co
fn test_load_should_decode_the_response_as_gzip_when_response_headers_have_content_encoding_gzip() {
let handler = move |_: HyperRequest, mut response: HyperResponse| {
response.headers_mut().set(ContentEncoding(vec![Encoding::Gzip]));
- let mut e = GzEncoder::new(Vec::new(), Compression::Default);
+ let mut e = GzEncoder::new(Vec::new(), Compression::default());
e.write(b"Yay!").unwrap();
let encoded_content = e.finish().unwrap();
response.send(&encoded_content).unwrap();