From ad77709c073a69a921041fb8666beffb26f889f6 Mon Sep 17 00:00:00 2001 From: Michael Friedrich Date: Sun, 11 May 2014 15:08:32 +0200 Subject: [PATCH] Rename host.total_* runtime macros to host.num_*. Fixes #6188 --- lib/icinga/host.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/icinga/host.cpp b/lib/icinga/host.cpp index 9b49bcb46..e7f76c332 100644 --- a/lib/icinga/host.cpp +++ b/lib/icinga/host.cpp @@ -235,18 +235,18 @@ bool Host::ResolveMacro(const String& macro, const CheckResult::Ptr&, String *re } else if (macro == "duration_sec") { *result = Convert::ToString((long)(Utility::GetTime() - GetLastStateChange())); return true; - } else if (macro == "total_services" || macro == "total_services_ok" || macro == "total_services_warning" - || macro == "total_services_unknown" || macro == "total_services_critical") { + } else if (macro == "num_services" || macro == "num_services_ok" || macro == "num_services_warning" + || macro == "num_services_unknown" || macro == "num_services_critical") { int filter = -1; int count = 0; - if (macro == "total_services_ok") + if (macro == "num_services_ok") filter = ServiceOK; - else if (macro == "total_services_warning") + else if (macro == "num_services_warning") filter = ServiceWarning; - else if (macro == "total_services_unknown") + else if (macro == "num_services_unknown") filter = ServiceUnknown; - else if (macro == "total_services_critical") + else if (macro == "num_services_critical") filter = ServiceCritical; BOOST_FOREACH(const Service::Ptr& service, GetServices()) { -- 2.40.0