mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-28 03:27:44 +00:00
Fix unsafe attribute used without unsafe
This commit is contained in:
parent
e0fbced116
commit
2739c19330
6 changed files with 55 additions and 20 deletions
|
@ -324,7 +324,9 @@ fn test_filter_with_env_var_set() {
|
|||
RandomFile::new(&at, name).add_lines(n_lines);
|
||||
|
||||
let env_var_value = "some-value";
|
||||
env::set_var("FILE", env_var_value);
|
||||
unsafe {
|
||||
env::set_var("FILE", env_var_value);
|
||||
}
|
||||
ucmd.args(&[format!("--filter={}", "cat > $FILE").as_str(), name])
|
||||
.succeeds();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue