From 0e2446206451c391b3c1e007cf7a8ed7b24fc6a1 Mon Sep 17 00:00:00 2001 From: "Alexander A. Klimov" Date: Wed, 4 Mar 2020 14:58:32 +0100 Subject: [PATCH] Fire Checkable::OnFlappingChange only if flapping is enabled refs #7885 --- lib/icinga/checkable-flapping.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/icinga/checkable-flapping.cpp b/lib/icinga/checkable-flapping.cpp index 91efb6284..3b49a6cdd 100644 --- a/lib/icinga/checkable-flapping.cpp +++ b/lib/icinga/checkable-flapping.cpp @@ -70,7 +70,9 @@ void Checkable::UpdateFlappingStatus(bool stateChange) double ee = GetLastCheckResult()->GetExecutionEnd(); - OnFlappingChange(this, ee); + if (GetEnableFlapping() && IcingaApplication::GetInstance()->GetEnableFlapping()) { + OnFlappingChange(this, ee); + } SetFlappingLastChange(ee); }