mirror of
https://github.com/rustdesk/rustdesk.git
synced 2026-04-03 20:01:28 +03:00
remove many unwrap and enum_value_or_default
Signed-off-by: 21pages <pages21@163.com>
This commit is contained in:
@@ -725,7 +725,7 @@ pub fn run_me<T: AsRef<std::ffi::OsStr>>(args: Vec<T>) -> std::io::Result<std::p
|
||||
}
|
||||
#[cfg(feature = "appimage")]
|
||||
{
|
||||
let appdir = std::env::var("APPDIR").unwrap();
|
||||
let appdir = std::env::var("APPDIR").map_err(|_| std::io::ErrorKind::Other)?;
|
||||
let appimage_cmd = std::path::Path::new(&appdir).join("AppRun");
|
||||
log::info!("path: {:?}", appimage_cmd);
|
||||
return std::process::Command::new(appimage_cmd).args(&args).spawn();
|
||||
|
||||
Reference in New Issue
Block a user