Skip to content

Commit

Permalink
Prevents unwrapping invalid location url domains
Browse files Browse the repository at this point in the history
  • Loading branch information
samfoo committed Aug 31, 2015
1 parent 9d0f418 commit 43e0c4a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion components/net/http_loader.rs
Original file line number Diff line number Diff line change
Expand Up @@ -460,7 +460,7 @@ pub fn load<A>(load_data: LoadData,
loop {
iters = iters + 1;

if &*url.scheme != "https" && request_must_be_secured(&url, &resource_mgr_chan) {
if &*url.scheme == "http" && request_must_be_secured(&url, &resource_mgr_chan) {
info!("{} is in the strict transport security list, requesting secure host", url);
url = secure_url(&url);
}
Expand Down

0 comments on commit 43e0c4a

Please sign in to comment.