mac_wakeup resolve panic possibility
This commit is contained in:
parent
f14faa85d2
commit
08278059ac
@ -96,8 +96,8 @@ pub fn new() -> ServerPtr {
|
|||||||
fn mac_wakeup(){
|
fn mac_wakeup(){
|
||||||
#[cfg(target_os = "macos")]{
|
#[cfg(target_os = "macos")]{
|
||||||
use std::process::Command;
|
use std::process::Command;
|
||||||
Command::new("/usr/bin/caffeinate").arg("-u").arg("-t 5").spawn().expect("failed to execute caffeinate");
|
Command::new("/usr/bin/caffeinate").arg("-u").arg("-t 5").spawn().ok();
|
||||||
println!("wake up macos");
|
log::info!("wake up macos");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user