diff options
Diffstat (limited to 'src/sys/wait.rs')
-rw-r--r-- | src/sys/wait.rs | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/src/sys/wait.rs b/src/sys/wait.rs index ba5dc27a..53c6a5f2 100644 --- a/src/sys/wait.rs +++ b/src/sys/wait.rs @@ -104,16 +104,11 @@ impl WaitStatus { pub fn pid(&self) -> Option<Pid> { use self::WaitStatus::*; match *self { - Exited(p, _) => Some(p), - Signaled(p, _, _) => Some(p), - Stopped(p, _) => Some(p), - Continued(p) => Some(p), + Exited(p, _) | Signaled(p, _, _) | + Stopped(p, _) | Continued(p) => Some(p), StillAlive => None, - - #[cfg(any(target_os = "linux", target_os = "android"))] - PtraceEvent(p, _, _) => Some(p), - #[cfg(any(target_os = "linux", target_os = "android"))] - PtraceSyscall(p) => Some(p), + #[cfg(any(target_os = "android", target_os = "linux"))] + PtraceEvent(p, _, _) | PtraceSyscall(p) => Some(p), } } } |