mirror of
https://github.com/Icinga/icinga2.git
synced 2025-09-22 17:28:02 +02:00
Get local endpoint if FromClient is not set and origin is local
This commit is contained in:
parent
291a9c7bd2
commit
00a4d2c2eb
@ -77,7 +77,12 @@ void ClusterEvents::EnqueueCheck(const MessageOrigin::Ptr& origin, const Diction
|
||||
|
||||
void ClusterEvents::ExecuteCheckFromQueue(const MessageOrigin::Ptr& origin, const Dictionary::Ptr& params) {
|
||||
|
||||
Endpoint::Ptr sourceEndpoint = origin->FromClient->GetEndpoint();
|
||||
Endpoint::Ptr sourceEndpoint;
|
||||
if (origin->FromClient) {
|
||||
sourceEndpoint = origin->FromClient->GetEndpoint();
|
||||
} else if (origin->IsLocal()){
|
||||
sourceEndpoint = Endpoint::GetLocalEndpoint();
|
||||
}
|
||||
|
||||
if (!sourceEndpoint || (origin->FromZone && !Zone::GetLocalZone()->IsChildOf(origin->FromZone))) {
|
||||
Log(LogNotice, "ClusterEvents")
|
||||
|
Loading…
x
Reference in New Issue
Block a user