diff --git a/Cargo.toml b/Cargo.toml index 6864b51..75a5fcf 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -17,6 +17,9 @@ exclude = ["/.*"] [package.metadata.docs.rs] rustdoc-args = ["--cfg", "docsrs"] +[lints.rust] +unexpected_cfgs = { level = "warn", check-cfg = ['cfg(polling_test_poll_backend)', 'cfg(polling_test_epoll_pipe)'] } + [dependencies] cfg-if = "1" tracing = { version = "0.1.37", default-features = false } diff --git a/src/epoll.rs b/src/epoll.rs index 2f1a661..331874b 100644 --- a/src/epoll.rs +++ b/src/epoll.rs @@ -201,7 +201,7 @@ impl Poller { (_, Some(t)) if t == Duration::from_secs(0) => 0, (None, Some(t)) => { // Round up to a whole millisecond. - let mut ms = t.as_millis().try_into().unwrap_or(std::i32::MAX); + let mut ms = t.as_millis().try_into().unwrap_or(i32::MAX); if Duration::from_millis(ms as u64) < t { ms = ms.saturating_add(1); }