diff options
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/extra/m_mysql.cpp | 2 | ||||
-rw-r--r-- | src/modules/extra/m_pgsql.cpp | 2 | ||||
-rw-r--r-- | src/modules/extra/m_sqlauth.cpp | 4 | ||||
-rw-r--r-- | src/modules/extra/m_sqllog.cpp | 2 | ||||
-rw-r--r-- | src/modules/extra/m_sqloper.cpp | 4 | ||||
-rw-r--r-- | src/modules/extra/m_sqlutils.cpp | 4 | ||||
-rw-r--r-- | src/modules/extra/m_testclient.cpp | 4 | ||||
-rw-r--r-- | src/modules/m_hostchange.cpp | 4 | ||||
-rw-r--r-- | src/modules/m_securelist.cpp | 4 |
9 files changed, 19 insertions, 11 deletions
diff --git a/src/modules/extra/m_mysql.cpp b/src/modules/extra/m_mysql.cpp index a6fa7ab8e..5eaa0e8d3 100644 --- a/src/modules/extra/m_mysql.cpp +++ b/src/modules/extra/m_mysql.cpp @@ -808,7 +808,7 @@ class ModuleSQL : public Module { throw ModuleException("m_mysql: Failed to create dispatcher thread: " + std::string(strerror(errno))); } - if (!Srv->PublishFeature("SQL", this)) + if (!ServerInstance->PublishFeature("SQL", this)) { /* Tell worker thread to exit NOW */ giveup = true; diff --git a/src/modules/extra/m_pgsql.cpp b/src/modules/extra/m_pgsql.cpp index d488bed8e..988700d41 100644 --- a/src/modules/extra/m_pgsql.cpp +++ b/src/modules/extra/m_pgsql.cpp @@ -522,7 +522,7 @@ public: ModulePgSQL(Server* Me) : Module::Module(Me), Srv(Me), currid(0) { - log(DEBUG, "%s 'SQL' feature", Srv->PublishFeature("SQL", this) ? "Published" : "Couldn't publish"); + log(DEBUG, "%s 'SQL' feature", ServerInstance->PublishFeature("SQL", this) ? "Published" : "Couldn't publish"); sqlsuccess = new char[strlen(SQLSUCCESS)+1]; diff --git a/src/modules/extra/m_sqlauth.cpp b/src/modules/extra/m_sqlauth.cpp index bc72e0e0c..960a3c540 100644 --- a/src/modules/extra/m_sqlauth.cpp +++ b/src/modules/extra/m_sqlauth.cpp @@ -48,7 +48,7 @@ public: ModuleSQLAuth(Server* Me) : Module::Module(Me), Srv(Me) { - SQLutils = Srv->FindFeature("SQLutils"); + SQLutils = ServerInstance->FindFeature("SQLutils"); if(SQLutils) { @@ -104,7 +104,7 @@ public: { Module* target; - target = Srv->FindFeature("SQL"); + target = ServerInstance->FindFeature("SQL"); if(target) { diff --git a/src/modules/extra/m_sqllog.cpp b/src/modules/extra/m_sqllog.cpp index a7d73af18..b2ddf1c5d 100644 --- a/src/modules/extra/m_sqllog.cpp +++ b/src/modules/extra/m_sqllog.cpp @@ -279,7 +279,7 @@ class ModuleSQLLog : public Module Conf = new ConfigReader(); dbid = Conf->ReadValue("sqllog","dbid",0); // database id of a database configured in sql module DELETE(Conf); - SQLModule = Srv->FindFeature("SQL"); + SQLModule = ServerInstance->FindFeature("SQL"); if (!SQLModule) log(DEFAULT,"WARNING: m_sqllog.so could not initialize because an SQL module is not loaded. Load the module and rehash your server."); return (SQLModule); diff --git a/src/modules/extra/m_sqloper.cpp b/src/modules/extra/m_sqloper.cpp index 17188ed68..7e905d691 100644 --- a/src/modules/extra/m_sqloper.cpp +++ b/src/modules/extra/m_sqloper.cpp @@ -44,7 +44,7 @@ public: ModuleSQLOper(Server* Me) : Module::Module(Me), Srv(Me) { - SQLutils = Srv->FindFeature("SQLutils"); + SQLutils = ServerInstance->FindFeature("SQLutils"); if (SQLutils) { @@ -91,7 +91,7 @@ public: { Module* target; - target = Srv->FindFeature("SQL"); + target = ServerInstance->FindFeature("SQL"); if (target) { diff --git a/src/modules/extra/m_sqlutils.cpp b/src/modules/extra/m_sqlutils.cpp index bbda7f3ea..f2085cbcd 100644 --- a/src/modules/extra/m_sqlutils.cpp +++ b/src/modules/extra/m_sqlutils.cpp @@ -31,6 +31,8 @@ /* $ModDesc: Provides some utilities to SQL client modules, such as mapping queries to users and channels */ +extern InspIRCd* ServerInstance; + typedef std::map<unsigned long, userrec*> IdUserMap; typedef std::map<unsigned long, chanrec*> IdChanMap; typedef std::list<unsigned long> AssocIdList; @@ -47,7 +49,7 @@ public: ModuleSQLutils(Server* Me) : Module::Module(Me), Srv(Me) { - log(DEBUG, "%s 'SQLutils' feature", Srv->PublishFeature("SQLutils", this) ? "Published" : "Couldn't publish"); + log(DEBUG, "%s 'SQLutils' feature", ServerInstance->PublishFeature("SQLutils", this) ? "Published" : "Couldn't publish"); } void Implements(char* List) diff --git a/src/modules/extra/m_testclient.cpp b/src/modules/extra/m_testclient.cpp index 6aec581ae..a5744f240 100644 --- a/src/modules/extra/m_testclient.cpp +++ b/src/modules/extra/m_testclient.cpp @@ -8,6 +8,8 @@ #include "configreader.h" #include "m_sqlv2.h" +extern InspIRCd* ServerInstance; + class ModuleTestClient : public Module { private: @@ -31,7 +33,7 @@ public: virtual void OnBackgroundTimer(time_t foo) { - Module* target = Srv->FindFeature("SQL"); + Module* target = ServerInstance->FindFeature("SQL"); if(target) { diff --git a/src/modules/m_hostchange.cpp b/src/modules/m_hostchange.cpp index 354eea3ed..d4da6d1ff 100644 --- a/src/modules/m_hostchange.cpp +++ b/src/modules/m_hostchange.cpp @@ -24,6 +24,8 @@ using namespace std; /* $ModDesc: Provides masking of user hostnames in a different way to m_cloaking */ +extern InspIRCd* ServerInstance; + class Host : public classbase { public: @@ -58,7 +60,7 @@ class ModuleHostChange : public Module Priority Prioritize() { - return (Priority)Srv->PriorityAfter("m_cloaking.so"); + return (Priority)ServerInstance->PriorityAfter("m_cloaking.so"); } void Implements(char* List) diff --git a/src/modules/m_securelist.cpp b/src/modules/m_securelist.cpp index 232a083be..00e860467 100644 --- a/src/modules/m_securelist.cpp +++ b/src/modules/m_securelist.cpp @@ -27,6 +27,8 @@ using namespace std; extern time_t TIME; /* $ModDesc: A module overriding /list, and making it safe - stop those sendq problems. */ + +extern InspIRCd* ServerInstance; class ModuleSecureList : public Module { @@ -82,7 +84,7 @@ class ModuleSecureList : public Module virtual Priority Prioritize() { - return (Priority)Srv->PriorityBefore("m_safelist.so"); + return (Priority)ServerInstance->PriorityBefore("m_safelist.so"); } }; |