From: Gunnar Beutner Date: Fri, 6 Sep 2013 11:34:11 +0000 (+0200) Subject: cluster: Fix handling messages that don't have a timestamp. X-Git-Tag: v0.0.3~596 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a00a28d31bc1ab9a5e190b737073303dc9f6903f;p=icinga2 cluster: Fix handling messages that don't have a timestamp. --- diff --git a/components/cluster/clustercomponent.cpp b/components/cluster/clustercomponent.cpp index b3c5e4ecb..0d303d643 100644 --- a/components/cluster/clustercomponent.cpp +++ b/components/cluster/clustercomponent.cpp @@ -769,7 +769,7 @@ void ClusterComponent::AcknowledgementClearedHandler(const Service::Ptr& service void ClusterComponent::MessageHandler(const Endpoint::Ptr& sender, const Dictionary::Ptr& message) { - if (sender->GetRemoteLogPosition() + 10 < message->Get("ts")) { + if (message->Contains("ts") && sender->GetRemoteLogPosition() + 10 < message->Get("ts")) { Dictionary::Ptr lparams = boost::make_shared(); lparams->Set("log_position", message->Get("ts"));