mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2026-01-06 21:32:58 +00:00
fix: use saturating in gc tracker (#7369)
chore: use saturating Signed-off-by: discord9 <discord9@163.com>
This commit is contained in:
@@ -50,7 +50,7 @@ impl GcScheduler {
|
|||||||
let now = Instant::now();
|
let now = Instant::now();
|
||||||
|
|
||||||
// Check if enough time has passed since last cleanup
|
// Check if enough time has passed since last cleanup
|
||||||
if now.duration_since(last_cleanup) < self.config.tracker_cleanup_interval {
|
if now.saturating_duration_since(last_cleanup) < self.config.tracker_cleanup_interval {
|
||||||
return Ok(());
|
return Ok(());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user