Fixed straggler error
This commit is contained in:
parent
f41f45f600
commit
ddae5cc24f
1 changed files with 1 additions and 4 deletions
|
@ -63,10 +63,7 @@ fn daemonize(options: &getopts::Matches) -> Result<()> {
|
||||||
}
|
}
|
||||||
let mut log_file = utils::get_data_root()?;
|
let mut log_file = utils::get_data_root()?;
|
||||||
log_file.push("polaris.log");
|
log_file.push("polaris.log");
|
||||||
let pid = match daemonize_redirect(Some(&log_file), Some(&log_file), ChdirMode::NoChdir) {
|
let pid = daemonize_redirect(Some(&log_file), Some(&log_file), ChdirMode::NoChdir)?;
|
||||||
Ok(p) => p,
|
|
||||||
Err(_) => bail!(ErrorKind::DaemonError),
|
|
||||||
};
|
|
||||||
let mut pid_path = utils::get_data_root()?;
|
let mut pid_path = utils::get_data_root()?;
|
||||||
pid_path.push("polaris.pid");
|
pid_path.push("polaris.pid");
|
||||||
let mut file = File::create(pid_path)?;
|
let mut file = File::create(pid_path)?;
|
||||||
|
|
Loading…
Add table
Reference in a new issue