From: Maxim Mamontov Date: Fri, 20 Jun 2014 18:33:20 +0000 (+0300) Subject: Removed unused variables. X-Git-Url: https://git.stg.codes/stg.git/commitdiff_plain/e02bdbcbe32883818ff31548917ef6df9f7a0e9d Removed unused variables. --- diff --git a/projects/stargazer/plugins/configuration/sgconfig/configproto.h b/projects/stargazer/plugins/configuration/sgconfig/configproto.h index d73498ff..2b76c413 100644 --- a/projects/stargazer/plugins/configuration/sgconfig/configproto.h +++ b/projects/stargazer/plugins/configuration/sgconfig/configproto.h @@ -32,6 +32,7 @@ #include #include +#include "stg/module_settings.h" #include "stg/os_int.h" #include diff --git a/projects/stargazer/plugins/configuration/sgconfig/stgconfig.cpp b/projects/stargazer/plugins/configuration/sgconfig/stgconfig.cpp index 3f6df219..7a0bf323 100644 --- a/projects/stargazer/plugins/configuration/sgconfig/stgconfig.cpp +++ b/projects/stargazer/plugins/configuration/sgconfig/stgconfig.cpp @@ -1,13 +1,12 @@ -#include +#include "stgconfig.h" + +#include "stg/plugin_creator.h" +#include "stg/common.h" -#include #include +#include -#include "stg/tariffs.h" -#include "stg/admins.h" -#include "stg/users.h" -#include "stg/plugin_creator.h" -#include "stgconfig.h" +#include //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- @@ -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()) { diff --git a/projects/stargazer/plugins/configuration/sgconfig/stgconfig.h b/projects/stargazer/plugins/configuration/sgconfig/stgconfig.h index a3da3895..7a089eb0 100644 --- a/projects/stargazer/plugins/configuration/sgconfig/stgconfig.h +++ b/projects/stargazer/plugins/configuration/sgconfig/stgconfig.h @@ -1,14 +1,14 @@ #ifndef STGCONFIG_H #define STGCONFIG_H -#include - -#include +#include "configproto.h" #include "stg/plugin.h" -#include "stg/store.h" #include "stg/logger.h" -#include "configproto.h" + +#include + +#include 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; }; //-----------------------------------------------------------------------------