]> git.stg.codes - stg.git/blobdiff - projects/stargazer/plugins/configuration/rpcconfig/rpcconfig.cpp
Include common headers in rpcconfig.cpp
[stg.git] / projects / stargazer / plugins / configuration / rpcconfig / rpcconfig.cpp
index 46905b15366e539b319ad4010cf72b72e1156e6a..7d764a7d3519d9418b2eb471dd3c8e1299b1d6d5 100644 (file)
@@ -3,14 +3,9 @@
 
 #include "rpcconfig.h"
 
-#include "../../../admin.h"
-#include "../../../admins.h"
-#include "../../../users.h"
-#include "../../../tariffs.h"
-#include "../../../traffcounter.h"
-#include "../../../settings.h"
-#include "base_store.h"
-#include "base_settings.h"
+#include "admin.h"
+#include "module_settings.h"
+#include "common.h"
 
 #include "info_methods.h"
 #include "users_methods.h"
@@ -18,8 +13,7 @@
 #include "admins_methods.h"
 #include "messages_methods.h"
 
-class RPC_CONFIG_CREATOR
-{
+class RPC_CONFIG_CREATOR {
 private:
     RPC_CONFIG * rpcconfig;
 
@@ -27,16 +21,16 @@ public:
     RPC_CONFIG_CREATOR()
         : rpcconfig(new RPC_CONFIG())
         {
-        };
+        }
     ~RPC_CONFIG_CREATOR()
         {
         delete rpcconfig;
-        };
+        }
 
     RPC_CONFIG * GetPlugin()
         {
         return rpcconfig;
-        };
+        }
 };
 
 RPC_CONFIG_CREATOR rpcc;
@@ -48,7 +42,7 @@ RPC_CONFIG_SETTINGS::RPC_CONFIG_SETTINGS()
 {
 }
 
-int RPC_CONFIG_SETTINGS::ParseIntInRange(const string & str,
+int RPC_CONFIG_SETTINGS::ParseIntInRange(const std::string & str,
                                          int min,
                                          int max,
                                          int * val)
@@ -113,9 +107,15 @@ return rpcc.GetPlugin();
 }
 
 RPC_CONFIG::RPC_CONFIG()
-    : rpcServer(NULL)
+    : users(NULL),
+      admins(NULL),
+      tariffs(NULL),
+      store(NULL),
+      stgSettings(NULL),
+      rpcServer(NULL),
+      running(false),
+      stopped(true)
 {
-
 }
 
 RPC_CONFIG::~RPC_CONFIG()