summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Mason <clm@fb.com>2024-04-23 10:52:37 -0700
committerChris Mason <clm@fb.com>2024-04-23 10:52:37 -0700
commitd1f344c004279e733eb363d28ca806ca1324ad2a (patch)
treeecaa9220029359a23ae41696137d88d7f11d5028
parente8ddaae2240898033cd7e877e3b6c610e30e6a4c (diff)
downloadsimoop-d1f344c004279e733eb363d28ca806ca1324ad2a.tar.gz
Fix interval reporting for zero runtimeHEADmaster
-r 0 makes us run forever, we shouldn't set the interval to zero in this case. Signed-off-by: Chris Mason <clm@fb.com>
-rw-r--r--simoop.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/simoop.c b/simoop.c
index 81204b9..7c7fc04 100644
--- a/simoop.c
+++ b/simoop.c
@@ -1929,7 +1929,7 @@ static void sleep_for_runtime(struct thread_data *worker_threads_mem)
save_vmstat_rates(&vmstat_info);
save_instant_vmstat_rates(&vmstat_info);
- if (interval_seconds > runtime)
+ if (interval_seconds > runtime && runtime > 0)
interval_seconds = runtime;
while(!stopping) {