mirror of
https://github.com/servo/servo.git
synced 2025-08-06 22:15:33 +01:00
Auto merge of #14284 - nox:fnv, r=Wafflespeanut
Use FnvHasher in http_loader::load Should help with #11100. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/14284) <!-- Reviewable:end -->
This commit is contained in:
commit
7e34f4cb5b
6 changed files with 28 additions and 24 deletions
|
@ -16,6 +16,7 @@ content-blocker = "0.2.1"
|
|||
cookie = {version = "0.2.5", features = ["serialize-rustc"]}
|
||||
devtools_traits = {path = "../devtools_traits"}
|
||||
flate2 = "0.2.0"
|
||||
fnv = "1.0"
|
||||
hyper = "0.9.9"
|
||||
hyper_serde = "0.1.4"
|
||||
immeta = "0.3.1"
|
||||
|
|
|
@ -11,6 +11,7 @@ use cookie_storage::CookieStorage;
|
|||
use devtools_traits::{ChromeToDevtoolsControlMsg, DevtoolsControlMsg, HttpRequest as DevtoolsHttpRequest};
|
||||
use devtools_traits::{HttpResponse as DevtoolsHttpResponse, NetworkEvent};
|
||||
use flate2::read::{DeflateDecoder, GzDecoder};
|
||||
use fnv::FnvHashSet;
|
||||
use hsts::{HstsEntry, HstsList, secure_url};
|
||||
use hyper::Error as HttpError;
|
||||
use hyper::LanguageTag;
|
||||
|
@ -42,7 +43,6 @@ use resource_thread::{AuthCache, AuthCacheEntry, CancellationListener, send_erro
|
|||
use servo_url::ServoUrl;
|
||||
use std::borrow::{Cow, ToOwned};
|
||||
use std::boxed::FnBox;
|
||||
use std::collections::HashSet;
|
||||
use std::error::Error;
|
||||
use std::fmt;
|
||||
use std::io::{self, Cursor, Read, Write};
|
||||
|
@ -898,7 +898,7 @@ pub fn load<A, B>(load_data: &LoadData,
|
|||
let mut iters = 0;
|
||||
// URL of the document being loaded, as seen by all the higher-level code.
|
||||
let mut doc_url = load_data.url.clone();
|
||||
let mut redirected_to = HashSet::new();
|
||||
let mut redirected_to = FnvHashSet::with_hasher(Default::default());
|
||||
let mut method = load_data.method.clone();
|
||||
// URL of referrer - to be updated with redirects
|
||||
let mut referrer_url = load_data.referrer_url.clone();
|
||||
|
|
|
@ -18,6 +18,7 @@ extern crate content_blocker as content_blocker_parser;
|
|||
extern crate cookie as cookie_rs;
|
||||
extern crate devtools_traits;
|
||||
extern crate flate2;
|
||||
extern crate fnv;
|
||||
extern crate hyper;
|
||||
extern crate hyper_serde;
|
||||
extern crate immeta;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue