From: Gunnar Beutner Date: Wed, 9 May 2012 13:09:14 +0000 (+0200) Subject: Bugfix for the welcome message. X-Git-Tag: v0.0.1~537 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a582b2c191ef088d32913039ce67157a3de99e0b;p=icinga2 Bugfix for the welcome message. --- diff --git a/components/discovery/discoverycomponent.cpp b/components/discovery/discoverycomponent.cpp index bd1f3e1bf..7d42b0221 100644 --- a/components/discovery/discoverycomponent.cpp +++ b/components/discovery/discoverycomponent.cpp @@ -484,7 +484,9 @@ void DiscoveryComponent::ProcessDiscoveryMessage(string identity, DiscoveryMessa if (IsBroker()) SendDiscoveryMessage("discovery::NewComponent", identity, Endpoint::Ptr()); - if (endpoint) + /* don't send a welcome message for discovery::RegisterComponent + messages unless we're a broker */ + if (endpoint && (trusted || IsBroker())) FinishDiscoverySetup(endpoint); }