Merge pull request #5245 from Icinga/fix/downtime-host-trigger

Fix that host downtimes might be triggered even if their state is Up
This commit is contained in:
Michael Friedrich 2017-05-11 15:07:37 +02:00 committed by GitHub
commit ed33a269b3
1 changed files with 1 additions and 1 deletions

View File

@ -134,7 +134,7 @@ void Downtime::Start(bool runtimeCreated)
* this downtime now *after* it has been added (important
* for DB IDO, etc.)
*/
if (checkable->GetStateRaw() != ServiceOK) {
if (!checkable->IsStateOK(checkable->GetStateRaw())) {
Log(LogNotice, "Downtime")
<< "Checkable '" << checkable->GetName() << "' already in a NOT-OK state."
<< " Triggering downtime now.";