From 4311991c03328f8e5136d0d81aa721d8f67318eb Mon Sep 17 00:00:00 2001 From: Bjoern Sikora Date: Wed, 19 May 2010 16:56:06 +0200 Subject: [PATCH] Moved BOOST macro for class registration from header to cpp file to avoid SEGFAULTING ;-). --- src/serializeservicecontainer.cpp | 10 ++++++++++ src/serializeservicecontainer.h | 10 ---------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/serializeservicecontainer.cpp b/src/serializeservicecontainer.cpp index b3857fc..7547d08 100644 --- a/src/serializeservicecontainer.cpp +++ b/src/serializeservicecontainer.cpp @@ -9,6 +9,16 @@ #include "serializeservicecontainer.h" +// Following boost macros are needed for serialization of derived classes through a base class pointer (Service *). +BOOST_CLASS_EXPORT_GUID(ServiceOds, "ServiceOds") +BOOST_CLASS_EXPORT_GUID(ServiceDhs, "ServiceDhs") +BOOST_CLASS_EXPORT_GUID(ServiceDyns, "ServiceDyns") +BOOST_CLASS_EXPORT_GUID(ServiceDyndns, "ServiceDyndns") +BOOST_CLASS_EXPORT_GUID(ServiceEasydns, "ServiceEasydns") +BOOST_CLASS_EXPORT_GUID(ServiceTzo, "ServiceTzo") +BOOST_CLASS_EXPORT_GUID(ServiceZoneedit, "ServiceZoneedit") +BOOST_CLASS_EXPORT_GUID(ServiceGnudip, "ServiceGnudip") + SerializeServiceContainer::SerializeServiceContainer() { diff --git a/src/serializeservicecontainer.h b/src/serializeservicecontainer.h index 85eac11..f5a4984 100644 --- a/src/serializeservicecontainer.h +++ b/src/serializeservicecontainer.h @@ -30,16 +30,6 @@ #include "service_zoneedit.h" #include "service_gnudip.h" -// Following boost macros are needed for serialization of derived classes through a base class pointer (Service *). -BOOST_CLASS_EXPORT_GUID(ServiceOds, "ServiceOds") -BOOST_CLASS_EXPORT_GUID(ServiceDhs, "ServiceDhs") -BOOST_CLASS_EXPORT_GUID(ServiceDyns, "ServiceDyns") -BOOST_CLASS_EXPORT_GUID(ServiceDyndns, "ServiceDyndns") -BOOST_CLASS_EXPORT_GUID(ServiceEasydns, "ServiceEasydns") -BOOST_CLASS_EXPORT_GUID(ServiceTzo, "ServiceTzo") -BOOST_CLASS_EXPORT_GUID(ServiceZoneedit, "ServiceZoneedit") -BOOST_CLASS_EXPORT_GUID(ServiceGnudip, "ServiceGnudip") - class SerializeServiceContainer { -- 1.7.1