From: Gunnar Beutner Date: Fri, 12 Oct 2012 08:16:03 +0000 (+0200) Subject: Don't write local-only objects to the state file. X-Git-Tag: v0.0.1~22 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ec0e319d8ab84f2b713e628c7de996d693621b1b;p=icinga2 Don't write local-only objects to the state file. --- diff --git a/lib/base/dynamicobject.cpp b/lib/base/dynamicobject.cpp index dde4510b2..9ee0f2960 100644 --- a/lib/base/dynamicobject.cpp +++ b/lib/base/dynamicobject.cpp @@ -375,6 +375,9 @@ void DynamicObject::DumpObjects(const String& filename) for (nt = tt->second.begin(); nt != tt->second.end(); nt++) { DynamicObject::Ptr object = nt->second; + if (object->IsLocal()) + continue; + Dictionary::Ptr persistentObject = boost::make_shared(); persistentObject->Set("type", object->GetType());