From 4596b44171797a0c7691194f75116998b3bd27e3 Mon Sep 17 00:00:00 2001 From: Yonas Habteab Date: Wed, 12 Mar 2025 14:20:01 +0100 Subject: [PATCH] Reset `no_more_notifications` on filter mismatch correctly Previously, if you enable flapping for a Checkable but the corresponding `Notification` object does not have `FlappingStart` or `FlappingEnd` types set, the `no_more_notifications` flag wasn't reset to false again. This commit ensures that this flag is always reset on `Recovery` even the type filter does not match including when we miss the `Recovery` due to Flapping state. --- lib/icinga/notification.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/icinga/notification.cpp b/lib/icinga/notification.cpp index 5b2964a84..23c06e480 100644 --- a/lib/icinga/notification.cpp +++ b/lib/icinga/notification.cpp @@ -365,7 +365,7 @@ void Notification::BeginExecuteNotification(NotificationType type, const CheckRe */ { ObjectLock olock(this); - if (type == NotificationRecovery && GetInterval() <= 0) + if (GetInterval() <= 0 && IsRecoveryOrFlappingEndAndCheckableIsOK(checkable, cr, type)) SetNoMoreNotifications(false); }