From 3a74316aab2ff194fcb11abe842dbb3ce9ad23f0 Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Wed, 27 Feb 2013 06:50:39 +0100 Subject: [PATCH] Fixed notifications for hard recoveries. --- lib/icinga/service-check.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/icinga/service-check.cpp b/lib/icinga/service-check.cpp index f1874d183..5bc4e2bc5 100644 --- a/lib/icinga/service-check.cpp +++ b/lib/icinga/service-check.cpp @@ -254,11 +254,10 @@ void Service::ApplyCheckResult(const Dictionary::Ptr& cr) long attempt = GetCurrentCheckAttempt(); if (cr->Get("state") == StateOK) { - if (old_state != StateOK && old_stateType == StateTypeHard) + if (old_state == StateOK && old_stateType == StateTypeSoft) { hardChange = true; // hard recovery - - if (old_state == StateOK) SetStateType(StateTypeHard); + } attempt = 1; recovery = true;