[go: nahoru, domu]

Skip to content

Commit

Permalink
Merge pull request #714 from zyy17/use-recommended-u64-max
Browse files Browse the repository at this point in the history
Modify 'std::u64::MAX' to 'u64::MAX'
  • Loading branch information
bacongobbler committed Feb 9, 2022
2 parents 63cca61 + de8e6f4 commit 35a84d5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions crates/kubelet/src/kubelet.rs
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ async fn start_plugin_registry(registrar: Option<Arc<PluginRegistry>>) -> anyhow
task::spawn(async {
loop {
// We run a delay here so we don't waste time on NOOP CPU cycles
tokio::time::sleep(tokio::time::Duration::from_secs(std::u64::MAX)).await;
tokio::time::sleep(tokio::time::Duration::from_secs(u64::MAX)).await;
}
})
.map_err(anyhow::Error::from)
Expand All @@ -206,7 +206,7 @@ async fn start_device_manager(device_manager: Option<Arc<DeviceManager>>) -> any
task::spawn(async {
loop {
// We run a delay here so we don't waste time on NOOP CPU cycles
tokio::time::sleep(tokio::time::Duration::from_secs(std::u64::MAX)).await;
tokio::time::sleep(tokio::time::Duration::from_secs(u64::MAX)).await;
}
})
.map_err(anyhow::Error::from)
Expand Down
2 changes: 1 addition & 1 deletion tests/device_plugin/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ impl DevicePlugin for MockDevicePlugin {
.unwrap();
loop {
// ListAndWatch should not end
tokio::time::sleep(tokio::time::Duration::from_secs(std::u64::MAX)).await;
tokio::time::sleep(tokio::time::Duration::from_secs(u64::MAX)).await;
}
});
Ok(Response::new(Box::pin(
Expand Down

0 comments on commit 35a84d5

Please sign in to comment.