Proper case for TimedOut variant
This commit is contained in:
parent
6dae26212d
commit
31d681ba2a
|
@ -127,7 +127,7 @@ pub enum BarrierError {
|
|||
Notify(NotifyError),
|
||||
FailedPipeCreation(Errno),
|
||||
FailedPolling(Errno),
|
||||
Timedout,
|
||||
TimedOut,
|
||||
}
|
||||
|
||||
impl From<NotifyError> for BarrierError {
|
||||
|
@ -145,7 +145,7 @@ impl Display for BarrierError {
|
|||
"Couldn't create pipe to serve as a notify syncronisation barrier : error {errno}."
|
||||
),
|
||||
Self::FailedPolling(errno) => write!(f, "poll failed with error : {errno}."),
|
||||
Self::Timedout => write!(f, "Notification synchronisation timed out."),
|
||||
Self::TimedOut => write!(f, "Notification synchronisation timed out."),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -156,7 +156,7 @@ impl Error for BarrierError {
|
|||
Self::Notify(source) => Some(source),
|
||||
Self::FailedPipeCreation(source) => Some(source),
|
||||
Self::FailedPolling(source) => Some(source),
|
||||
Self::Timedout => None,
|
||||
Self::TimedOut => None,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -186,7 +186,7 @@ impl Notifier {
|
|||
.map_err(BarrierError::FailedPolling)
|
||||
.and_then(|events| {
|
||||
if events == 0_usize {
|
||||
return Err(BarrierError::Timedout);
|
||||
return Err(BarrierError::TimedOut);
|
||||
}
|
||||
Ok(())
|
||||
})
|
||||
|
|
Loading…
Reference in a new issue