Service: be handled while host is down

This commit is contained in:
Alexander A. Klimov 2019-04-11 11:25:45 +02:00
parent 2b3511d8a6
commit ae18536b0f
2 changed files with 6 additions and 0 deletions

View File

@ -133,6 +133,11 @@ int Service::GetSeverity() const
return severity;
}
bool Service::GetHandled() const
{
return Checkable::GetHandled() || m_Host->GetProblem();
}
bool Service::IsStateOK(ServiceState state) const
{
return state == ServiceOK;

View File

@ -29,6 +29,7 @@ public:
Host::Ptr GetHost() const override;
int GetSeverity() const override;
bool GetHandled() const override;
bool ResolveMacro(const String& macro, const CheckResult::Ptr& cr, Value *result) const override;