remove echo, https://github.com/rustdesk/rustdesk/issues/504
This commit is contained in:
parent
5352bb74c8
commit
0d9d00baba
@ -781,13 +781,9 @@ fn get_default_install_info() -> (String, String, String, String) {
|
|||||||
|
|
||||||
fn get_default_install_path() -> String {
|
fn get_default_install_path() -> String {
|
||||||
let mut pf = "C:\\Program Files".to_owned();
|
let mut pf = "C:\\Program Files".to_owned();
|
||||||
if let Ok(output) = std::process::Command::new("echo")
|
if let Ok(x) = std::env::var("ProgramFiles") {
|
||||||
.arg("%ProgramFiles%")
|
if std::path::Path::new(&x).exists() {
|
||||||
.output()
|
pf = x;
|
||||||
{
|
|
||||||
let tmp = String::from_utf8_lossy(&output.stdout);
|
|
||||||
if !tmp.starts_with("%") {
|
|
||||||
pf = tmp.to_string();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#[cfg(target_pointer_width = "32")]
|
#[cfg(target_pointer_width = "32")]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user