diff --git a/Cargo.toml b/Cargo.toml index 54c04779546..024ef416e07 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -61,7 +61,7 @@ tempfile = "3.0" termcolor = "1.1" toml = "0.5.7" unicode-xid = "0.2.0" -url = "2.0" +url = "2.2.2" walkdir = "2.2" clap = "2.31.2" unicode-width = "0.1.5" diff --git a/crates/cargo-test-support/Cargo.toml b/crates/cargo-test-support/Cargo.toml index 9674579e249..8fe6268a430 100644 --- a/crates/cargo-test-support/Cargo.toml +++ b/crates/cargo-test-support/Cargo.toml @@ -21,4 +21,4 @@ remove_dir_all = "0.5" serde_json = "1.0" tar = { version = "0.4.18", default-features = false } toml = "0.5.7" -url = "2.0" +url = "2.2.2" diff --git a/crates/cargo-test-support/src/registry.rs b/crates/cargo-test-support/src/registry.rs index f0d19ad213d..9bca44f0b2c 100644 --- a/crates/cargo-test-support/src/registry.rs +++ b/crates/cargo-test-support/src/registry.rs @@ -178,12 +178,7 @@ impl RegistryBuilder { } if self.replace_crates_io { - init_registry( - registry_path(), - dl_url().into_string(), - api_url(), - api_path(), - ); + init_registry(registry_path(), dl_url().into(), api_url(), api_path()); } if self.alternative { diff --git a/crates/mdman/Cargo.lock b/crates/mdman/Cargo.lock index 124750d9d51..50948b5eca4 100644 --- a/crates/mdman/Cargo.lock +++ b/crates/mdman/Cargo.lock @@ -91,6 +91,16 @@ version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e88a8acf291dafb59c2d96e8f59828f3838bb1a70398823ade51a84de6a6deed" +[[package]] +name = "form_urlencoded" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5fc25a87fa4fd2094bffb06925852034d90a17f0d1e05197d4956d3555752191" +dependencies = [ + "matches", + "percent-encoding", +] + [[package]] name = "generic-array" version = "0.12.3" @@ -391,10 +401,11 @@ checksum = "f7fe0bb3479651439c9112f72b6c505038574c9fbb575ed1bf3b797fa39dd564" [[package]] name = "url" -version = "2.1.1" +version = "2.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "829d4a8476c35c9bf0bbce5a3b23f4106f79728039b726d292bb93bc106787cb" +checksum = "a507c383b2d33b5fc35d1861e77e6b383d158b2da5e14fe51b83dfedf6fd578c" dependencies = [ + "form_urlencoded", "idna", "matches", "percent-encoding", diff --git a/crates/mdman/Cargo.toml b/crates/mdman/Cargo.toml index 9d4329a16f8..4f17666b81c 100644 --- a/crates/mdman/Cargo.toml +++ b/crates/mdman/Cargo.toml @@ -12,7 +12,7 @@ handlebars = { version = "3.2.1", features = ["dir_source"] } pulldown-cmark = { version = "0.7.2", default-features = false } same-file = "1.0.6" serde_json = "1.0.56" -url = "2.1.1" +url = "2.2.2" [dev-dependencies] pretty_assertions = "0.6.1" diff --git a/crates/mdman/src/lib.rs b/crates/mdman/src/lib.rs index 8cbe466f9cf..0b17be59010 100644 --- a/crates/mdman/src/lib.rs +++ b/crates/mdman/src/lib.rs @@ -96,7 +96,7 @@ fn join_url<'a>(base: Option<&Url>, dest: CowStr<'a>) -> CowStr<'a> { let joined = base_url.join(&dest).unwrap_or_else(|e| { panic!("failed to join URL `{}` to `{}`: {}", dest, base_url, e) }); - joined.into_string().into() + String::from(joined).into() } } None => dest,