summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/ingestor.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ingestor.cpp b/src/ingestor.cpp
index e2c6f02..3e6e307 100644
--- a/src/ingestor.cpp
+++ b/src/ingestor.cpp
@@ -542,7 +542,7 @@ namespace WebStat {
purge->bindParam(0, std::format("{} days", settings.purgeDaysToKeep));
purge->bindParam(1, settings.purgeDeleteMax);
unsigned int purgedTotal {};
- while (stopAt > Job::LastRunTime::clock::now()) {
+ while (!terminated && stopAt > Job::LastRunTime::clock::now()) {
const auto purged = purge->execute();
purgedTotal += purged;
if (purged < settings.purgeDeleteMax) {