Skip to content

Commit

Permalink
fix: suppress and fix clippy warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
codyps committed May 2, 2024
1 parent b6f1f50 commit 3e8b4bb
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/bus/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -861,6 +861,9 @@ foreign_type! {
}

impl Bus {
// TODO: consider renaming all these methods so we don't have this one named `default()`, which
// confuses things with std::default::Default::default.
#[allow(clippy::should_implement_trait)]
#[inline]
pub fn default() -> crate::Result<Bus> {
let mut b = MaybeUninit::uninit();
Expand Down Expand Up @@ -1022,7 +1025,7 @@ impl BusRef {
pub fn wait(&mut self, timeout: Option<Duration>) -> super::Result<bool> {
Ok(sd_try!(ffi::bus::sd_bus_wait(
self.as_ptr(),
timeout.map(usec_from_duration).unwrap_or(std::u64::MAX)
timeout.map(usec_from_duration).unwrap_or(u64::MAX)
)) > 0)
}

Expand Down

0 comments on commit 3e8b4bb

Please sign in to comment.