From 345678d539058a7dad4724723d9fe11516de0ffd Mon Sep 17 00:00:00 2001 From: Tobias Kempf Date: Tue, 3 Dec 2024 11:11:40 +0100 Subject: [PATCH] Fix underflow --- mt-kahypar/dynamic/dynamic_partitioner.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mt-kahypar/dynamic/dynamic_partitioner.h b/mt-kahypar/dynamic/dynamic_partitioner.h index f35ee1c32..4b7970e29 100644 --- a/mt-kahypar/dynamic/dynamic_partitioner.h +++ b/mt-kahypar/dynamic/dynamic_partitioner.h @@ -15,7 +15,7 @@ namespace mt_kahypar::dyn { ds::StaticHypergraph& hypergraph_s = utils::cast(hypergraph); // If the number of changes is not specified or is greater than the number of changes in the file, we process all the changes - size_t changes_size = context.dynamic.max_changes == -1 ? changes.size() : std::min((size_t) context.dynamic.max_changes, changes.size()); + size_t changes_size = context.dynamic.max_changes == 0 ? changes.size() : std::min((size_t) context.dynamic.max_changes, changes.size()); DynamicStrategy* strategy;