diff --git a/cib/service.cpp b/cib/service.cpp index 8fcc28dd5..7d7d398c3 100644 --- a/cib/service.cpp +++ b/cib/service.cpp @@ -144,11 +144,18 @@ bool Service::IsReachable(void) const if (!service.HasLastCheckResult()) continue; - if (service.GetStateType() == StateTypeHard && service.GetState() != StateOK && - service.GetState() != StateWarning) - return false; + /* ignore soft states */ + if (service.GetStateType() == StateTypeSoft) + continue; + + /* ignore services states OK and Warning */ + if (service.GetState() == StateOK || + service.GetState() == StateWarning) + continue; + + return false; } - + return true; }