[icinga-checkins] icinga.org: icinga2/master: Fix GetInstance() methods for the DbType and config validator registry classes

git at icinga.org git at icinga.org
Sun Nov 9 13:07:00 CET 2014


Module: icinga2
Branch: master
Commit: 684ad2641aebeaba2c6be47444dece2b298ad195
URL:    https://git.icinga.org/?p=icinga2.git;a=commit;h=684ad2641aebeaba2c6be47444dece2b298ad195

Author: Gunnar Beutner <gunnar.beutner at netways.de>
Date:   Sun Nov  9 13:06:25 2014 +0100

Fix GetInstance() methods for the DbType and config validator registry classes

---

 lib/config/configcompiler.cpp |    6 ++++++
 lib/config/configcompiler.hpp |    5 +----
 lib/db_ido/dbtype.cpp         |    6 ++++++
 lib/db_ido/dbtype.hpp         |    5 +----
 4 files changed, 14 insertions(+), 8 deletions(-)

diff --git a/lib/config/configcompiler.cpp b/lib/config/configcompiler.cpp
index 9d61ec2..19c78f4 100644
--- a/lib/config/configcompiler.cpp
+++ b/lib/config/configcompiler.cpp
@@ -231,3 +231,9 @@ void ConfigCompiler::AddIncludeSearchDir(const String& dir)
 
 	m_IncludeSearchDirs.push_back(dir);
 }
+
+ConfigFragmentRegistry *ConfigFragmentRegistry::GetInstance(void)
+{
+	return Singleton<ConfigFragmentRegistry>::GetInstance();
+}
+
diff --git a/lib/config/configcompiler.hpp b/lib/config/configcompiler.hpp
index 3d1968b..3c3dd0d 100644
--- a/lib/config/configcompiler.hpp
+++ b/lib/config/configcompiler.hpp
@@ -80,10 +80,7 @@ private:
 class I2_CONFIG_API ConfigFragmentRegistry : public Registry<ConfigFragmentRegistry, String>
 {
 public:
-	static inline ConfigFragmentRegistry *GetInstance(void)
-	{
-		return Singleton<ConfigFragmentRegistry>::GetInstance();
-	}
+	static ConfigFragmentRegistry *GetInstance(void);
 };
 
 #define REGISTER_CONFIG_FRAGMENT(id, name, fragment) \
diff --git a/lib/db_ido/dbtype.cpp b/lib/db_ido/dbtype.cpp
index ca96498..2f197e6 100644
--- a/lib/db_ido/dbtype.cpp
+++ b/lib/db_ido/dbtype.cpp
@@ -125,3 +125,9 @@ std::set<DbType::Ptr> DbType::GetAllTypes(void)
 
 	return result;
 }
+
+DbTypeRegistry *DbTypeRegistry::GetInstance(void)
+{
+	return Singleton<DbTypeRegistry>::GetInstance();
+}
+
diff --git a/lib/db_ido/dbtype.hpp b/lib/db_ido/dbtype.hpp
index 199a04b..fda97ff 100644
--- a/lib/db_ido/dbtype.hpp
+++ b/lib/db_ido/dbtype.hpp
@@ -82,10 +82,7 @@ private:
 class I2_DB_IDO_API DbTypeRegistry : public Registry<DbTypeRegistry, DbType::Ptr>
 {
 public:
-	static inline DbTypeRegistry *GetInstance(void)
-	{
-		return Singleton<DbTypeRegistry>::GetInstance();
-	}
+	static DbTypeRegistry *GetInstance(void);
 };
 
 /**



More information about the icinga-checkins mailing list