mirror of
https://gitlab.steamos.cloud/holo/steamos-manager.git
synced 2025-07-15 10:46:41 -04:00
screenreader: Clean up orca process lookup
This commit is contained in:
parent
77e6bb9f06
commit
76ba2ff08b
1 changed files with 2 additions and 2 deletions
|
@ -443,9 +443,9 @@ impl<'dbus> OrcaManager<'dbus> {
|
||||||
let mut system = System::new();
|
let mut system = System::new();
|
||||||
system.refresh_all();
|
system.refresh_all();
|
||||||
|
|
||||||
let mut p = system.processes_by_name("orca".as_ref());
|
let mut p = system.processes_by_exact_name("orca".as_ref());
|
||||||
|
|
||||||
let pid = p.next().expect("No orca process found");
|
let pid = p.next().ok_or(anyhow!("No orca process found"))?;
|
||||||
Ok(Pid::from_raw(pid.pid().as_u32().try_into()?))
|
Ok(Pid::from_raw(pid.pid().as_u32().try_into()?))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue