]> granicus.if.org Git - icinga2/commitdiff
Execute checks locally if command_endpoint == local endpoint
authorMichael Friedrich <michael.friedrich@netways.de>
Fri, 5 Dec 2014 10:35:00 +0000 (11:35 +0100)
committerMichael Friedrich <michael.friedrich@netways.de>
Fri, 5 Dec 2014 10:35:00 +0000 (11:35 +0100)
fixes #7863

lib/icinga/checkable-check.cpp

index f3d90493d11d9cb42581ddfc8e031b0597441924..4da2f5e1e6a4212cab2e4763482ee4f30ff3c891 100644 (file)
@@ -259,7 +259,7 @@ void Checkable::ProcessCheckResult(const CheckResult::Ptr& cr, const MessageOrig
 
        Endpoint::Ptr command_endpoint = GetCommandEndpoint();
 
-       if (command_endpoint && GetExtension("agent_check")) {
+       if (command_endpoint && (Endpoint::GetLocalEndpoint() != command_endpoint) && GetExtension("agent_check")) {
                ApiListener::Ptr listener = ApiListener::GetInstance();
 
                if (listener) {