Skip to content

Commit 1a737af

Browse files
committed
Auto merge of #12462 - weihanglo:bump-cargo-version, r=ehuss
Bump cargo library to 0.72.2 for CVE patches
2 parents 7f1d04c + c7182e7 commit 1a737af

File tree

10 files changed

+25
-14
lines changed

10 files changed

+25
-14
lines changed

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ windows-sys = "0.48"
9595

9696
[package]
9797
name = "cargo"
98-
version = "0.72.1"
98+
version = "0.72.2"
9999
edition = "2021"
100100
license = "MIT OR Apache-2.0"
101101
homepage = "https://crates.io"

src/cargo/sources/git/known_hosts.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -408,7 +408,7 @@ fn check_ssh_known_hosts_loaded(
408408
// fingerprints (see FingerprintHash ssh config option). Here we only
409409
// support SHA256.
410410
let mut remote_fingerprint = cargo_util::Sha256::new();
411-
remote_fingerprint.update(remote_host_key.clone());
411+
remote_fingerprint.update(remote_host_key);
412412
let remote_fingerprint = STANDARD_NO_PAD.encode(remote_fingerprint.finish());
413413
let remote_host_key_encoded = STANDARD.encode(remote_host_key);
414414

tests/testsuite/bench.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -313,9 +313,8 @@ fn cargo_bench_failing_test() {
313313
[FINISHED] bench [optimized] target(s) in [..]
314314
[RUNNING] [..] (target/release/deps/foo-[..][EXE])",
315315
)
316-
.with_stdout_contains(
317-
"[..]thread '[..]' panicked at 'assertion failed: `(left == right)`[..]",
318-
)
316+
.with_stdout_contains("[..]thread '[..]' panicked at[..]")
317+
.with_stdout_contains("[..]assertion failed[..]")
319318
.with_stdout_contains("[..]left: `\"hello\"`[..]")
320319
.with_stdout_contains("[..]right: `\"nope\"`[..]")
321320
.with_stdout_contains("[..]src/main.rs:15[..]")

tests/testsuite/build_script_env.rs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,10 @@ fn rustc_bootstrap() {
117117
"#;
118118
let p = project()
119119
.file("Cargo.toml", &basic_manifest("has-dashes", "0.0.1"))
120-
.file("src/lib.rs", "#![feature(rustc_attrs)]")
120+
.file(
121+
"src/lib.rs",
122+
"#![allow(internal_features)] #![feature(rustc_attrs)]",
123+
)
121124
.file("build.rs", build_rs)
122125
.build();
123126
// RUSTC_BOOTSTRAP unset on stable should error
@@ -154,7 +157,10 @@ fn rustc_bootstrap() {
154157
// Tests for binaries instead of libraries
155158
let p = project()
156159
.file("Cargo.toml", &basic_manifest("foo", "0.0.1"))
157-
.file("src/main.rs", "#![feature(rustc_attrs)] fn main() {}")
160+
.file(
161+
"src/main.rs",
162+
"#![allow(internal_features)] #![feature(rustc_attrs)] fn main() {}",
163+
)
158164
.file("build.rs", build_rs)
159165
.build();
160166
// nightly should warn when there's no library whether or not RUSTC_BOOTSTRAP is set

tests/testsuite/cargo_features.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -295,6 +295,7 @@ fn allow_features_to_rustc() {
295295
.file(
296296
"src/lib.rs",
297297
r#"
298+
#![allow(internal_features)]
298299
#![feature(test_2018_feature)]
299300
"#,
300301
)

tests/testsuite/custom_target.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ use cargo_test_support::{basic_manifest, project};
44
use std::fs;
55

66
const MINIMAL_LIB: &str = r#"
7+
#![allow(internal_features)]
78
#![feature(no_core)]
89
#![feature(lang_items)]
910
#![no_core]
@@ -80,6 +81,7 @@ fn custom_target_dependency() {
8081
.file(
8182
"src/lib.rs",
8283
r#"
84+
#![allow(internal_features)]
8385
#![feature(no_core)]
8486
#![feature(lang_items)]
8587
#![feature(auto_traits)]

tests/testsuite/doc.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -756,6 +756,7 @@ fn doc_target() {
756756
.file(
757757
"src/lib.rs",
758758
r#"
759+
#![allow(internal_features)]
759760
#![feature(no_core, lang_items)]
760761
#![no_core]
761762

tests/testsuite/install.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1269,7 +1269,8 @@ fn reports_unsuccessful_subcommand_result() {
12691269
.run();
12701270
cargo_process("fail")
12711271
.with_status(101)
1272-
.with_stderr_contains("thread '[..]' panicked at 'explicit panic', [..]")
1272+
.with_stderr_contains("thread '[..]' panicked at [..]src/main.rs:1:[..]")
1273+
.with_stderr_contains("[..]explicit panic[..]")
12731274
.run();
12741275
}
12751276

tests/testsuite/test.rs

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -387,8 +387,9 @@ test test_hello ... FAILED
387387
failures:
388388
389389
---- test_hello stdout ----
390-
[..]thread '[..]' panicked at 'assertion failed:[..]",
390+
[..]thread '[..]' panicked at [..]",
391391
)
392+
.with_stdout_contains("[..]assertion failed[..]")
392393
.with_stdout_contains("[..]`(left == right)`[..]")
393394
.with_stdout_contains("[..]left: `\"hello\"`,[..]")
394395
.with_stdout_contains("[..]right: `\"nope\"`[..]")
@@ -437,10 +438,10 @@ test test_hello ... FAILED
437438
failures:
438439
439440
---- test_hello stdout ----
440-
[..]thread '[..]' panicked at 'assertion failed: false', \
441-
tests/footest.rs:1[..]
441+
[..]thread '[..]' panicked at [..]tests/footest.rs:1:[..]
442442
",
443443
)
444+
.with_stdout_contains("[..]assertion failed[..]")
444445
.with_stdout_contains(
445446
"\
446447
failures:
@@ -473,10 +474,10 @@ test test_hello ... FAILED
473474
failures:
474475
475476
---- test_hello stdout ----
476-
[..]thread '[..]' panicked at 'assertion failed: false', \
477-
src/lib.rs:1[..]
477+
[..]thread '[..]' panicked at [..]src/lib.rs:1:[..]
478478
",
479479
)
480+
.with_stdout_contains("[..]assertion failed[..]")
480481
.with_stdout_contains(
481482
"\
482483
failures:

0 commit comments

Comments
 (0)