X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/1b2ab8e6d556a8ed30d4feadc72263b3f4c86665..0ebb52df5d005faab367ad69616958974c5ae107:/stglibs/srvconf.lib/servconf.cpp

diff --git a/stglibs/srvconf.lib/servconf.cpp b/stglibs/srvconf.lib/servconf.cpp
index 430de3c1..e7ecfdf4 100644
--- a/stglibs/srvconf.lib/servconf.cpp
+++ b/stglibs/srvconf.lib/servconf.cpp
@@ -60,6 +60,7 @@ class SERVCONF::IMPL
 public:
     IMPL(const std::string & server, uint16_t port,
          const std::string & login, const std::string & password);
+    ~IMPL() { XML_ParserFree(parser); }
 
     const std::string & GetStrError() const;
     static void Start(void * data, const char * el, const char ** attr);
@@ -348,11 +349,13 @@ int ret = 0;
 if ((ret = nt.Connect()) != st_ok)
     {
     errorMsg = nt.GetError();
+    cp.Failure(errorMsg);
     return ret;
     }
 if ((ret = nt.Transact(request, ParserRecv, this)) != st_ok)
     {
     errorMsg = nt.GetError();
+    cp.Failure(errorMsg);
     return ret;
     }