summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2017-02-01 02:48:22 +0000
committerDan Goodliffe <dan@randomdan.homeip.net>2017-02-01 02:48:22 +0000
commitcb80d9a63ca7b18d0e9daabc4a59f1915eef0b98 (patch)
tree3240f339bcd799de1c909613ac8d5eb2bcf565a7
parentAdd service config file (diff)
downloadgentoobrowse-api-cb80d9a63ca7b18d0e9daabc4a59f1915eef0b98.tar.bz2
gentoobrowse-api-cb80d9a63ca7b18d0e9daabc4a59f1915eef0b98.tar.xz
gentoobrowse-api-cb80d9a63ca7b18d0e9daabc4a59f1915eef0b98.zip
Add explicit init and clean up of XML/XSLT things with the API instance
-rw-r--r--gentoobrowse-api/service/main.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/gentoobrowse-api/service/main.cpp b/gentoobrowse-api/service/main.cpp
index b7b18a2..8ac8a8b 100644
--- a/gentoobrowse-api/service/main.cpp
+++ b/gentoobrowse-api/service/main.cpp
@@ -7,10 +7,25 @@
#include "notificationsimpl.h"
#include "mailserverimpl.h"
+#include <libexslt/exslt.h>
+#include <libxslt/transform.h>
+
namespace Gentoo {
namespace Service {
class Api : public IceTray::Service {
public:
+ Api()
+ {
+ xmlInitParser();
+ // exsltRegisterAll();
+ }
+
+ ~Api()
+ {
+ xsltCleanupGlobals();
+ xmlCleanupParser();
+ }
+
void addObjects(const std::string &, const Ice::CommunicatorPtr & ic, const Ice::StringSeq &, const Ice::ObjectAdapterPtr & adp) override
{
auto db = getConnectionPool(ic, "postgresql", "GentooBrowseAPI");