Skip to content

Commit 2adbfa9

Browse files
committed
Unify temp path generation for non-android
1 parent d5e6bda commit 2adbfa9

File tree

1 file changed

+4
-4
lines changed
  • src/tools/remote-test-server/src

1 file changed

+4
-4
lines changed

src/tools/remote-test-server/src/main.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -83,12 +83,12 @@ fn main() {
8383
};
8484

8585
let listener = t!(TcpListener::bind(bind_addr));
86-
let work: PathBuf = if cfg!(windows) {
87-
env::var_os("RUST_TEMP").expect("Set RUST_TEMP to your preferred temp folder").into()
88-
} else if cfg!(target_os = "android") {
86+
let work: PathBuf = if cfg!(target_os = "android") {
8987
"/data/tmp/work".into()
9088
} else {
91-
"/tmp/work".into()
89+
let mut temp_dir = env::temp_dir();
90+
temp_dir.push("work");
91+
temp_dir
9292
};
9393
println!("listening!");
9494

0 commit comments

Comments
 (0)