]> git.stg.codes - stg.git/commitdiff
Removed unused variables.
authorMaxim Mamontov <faust.madf@gmail.com>
Fri, 20 Jun 2014 18:33:20 +0000 (21:33 +0300)
committerMaxim Mamontov <faust.madf@gmail.com>
Fri, 9 Jan 2015 20:25:56 +0000 (22:25 +0200)
projects/stargazer/plugins/configuration/sgconfig/configproto.h
projects/stargazer/plugins/configuration/sgconfig/stgconfig.cpp
projects/stargazer/plugins/configuration/sgconfig/stgconfig.h

index 2917567ea59167e0d0d05ad5ce8de93c7ece7b74..7f6929fe5ba986395fa0a19fed8e6163eadb6330 100644 (file)
@@ -32,6 +32,7 @@
 #include <list>
 #include <vector>
 
+#include "stg/module_settings.h"
 #include "stg/os_int.h"
 
 #include <expat.h>
index 3f6df2193b45265cb2fa8ead5f92089473a1bc0b..7a0bf323f9425c4a433913e4f88fa7abee33da28 100644 (file)
@@ -1,13 +1,12 @@
-#include <unistd.h>
+#include "stgconfig.h"
+
+#include "stg/plugin_creator.h"
+#include "stg/common.h"
 
-#include <csignal>
 #include <algorithm>
+#include <csignal>
 
-#include "stg/tariffs.h"
-#include "stg/admins.h"
-#include "stg/users.h"
-#include "stg/plugin_creator.h"
-#include "stgconfig.h"
+#include <unistd.h>
 
 //-----------------------------------------------------------------------------
 //-----------------------------------------------------------------------------
@@ -63,12 +62,7 @@ STG_CONFIG::STG_CONFIG()
       isRunning(false),
       logger(GetPluginLogger(GetStgLogger(), "conf_sg")),
       config(logger),
-      users(NULL),
-      admins(NULL),
-      tariffs(NULL),
-      store(NULL),
-      settings(),
-      stgSettings(NULL)
+      settings()
 {
 }
 //-----------------------------------------------------------------------------
@@ -88,11 +82,6 @@ if (isRunning)
 nonstop = true;
 
 config.SetPort(stgConfigSettings.GetPort());
-config.SetAdmins(admins);
-config.SetUsers(users);
-config.SetTariffs(tariffs);
-config.SetStgSettings(stgSettings);
-config.SetStore(store);
 
 if (config.Prepare())
     {
index a3da389525f553463467e1c29104898329509d80..7a089eb00caa36c137e75fae7704c17fa5335636 100644 (file)
@@ -1,14 +1,14 @@
 #ifndef STGCONFIG_H
 #define STGCONFIG_H
 
-#include <pthread.h>
-
-#include <string>
+#include "configproto.h"
 
 #include "stg/plugin.h"
-#include "stg/store.h"
 #include "stg/logger.h"
-#include "configproto.h"
+
+#include <string>
+
+#include <pthread.h>
 
 class STG_CONFIG_SETTINGS {
 public:
@@ -27,11 +27,11 @@ public:
     STG_CONFIG();
     virtual ~STG_CONFIG(){}
 
-    void                SetUsers(USERS * u) { users = u; }
-    void                SetTariffs(TARIFFS * t) { tariffs = t; }
-    void                SetAdmins(ADMINS * a) { admins = a; }
-    void                SetStore(STORE * s) { store = s; }
-    void                SetStgSettings(const SETTINGS * s) { stgSettings = s; }
+    void                SetUsers(USERS * users) { config.SetUsers(users); }
+    void                SetTariffs(TARIFFS * tariffs) { config.SetTariffs(tariffs); }
+    void                SetAdmins(ADMINS * admins) { config.SetAdmins(admins); }
+    void                SetStore(STORE * store) { config.SetStore(store); }
+    void                SetStgSettings(const SETTINGS * settings) { config.SetStgSettings(settings); }
     void                SetSettings(const MODULE_SETTINGS & s) { settings = s; }
     int                 ParseSettings();
 
@@ -58,12 +58,7 @@ private:
     bool                isRunning;
     PLUGIN_LOGGER       logger;
     CONFIGPROTO         config;
-    USERS *             users;
-    ADMINS *            admins;
-    TARIFFS *           tariffs;
-    STORE *             store;
     MODULE_SETTINGS     settings;
-    const SETTINGS *    stgSettings;
 };
 //-----------------------------------------------------------------------------