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