summaryrefslogtreecommitdiff
path: root/src/modules
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-06-17 13:35:07 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-06-17 13:35:07 +0000
commit7d68395f914977f34ea4032e94a5c21700d59cce (patch)
treedb2b62ad60de7b053a0de18ecd59726c218bd505 /src/modules
parentd523f0d4995548ad6d0a21a978c320dab047eb62 (diff)
More
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@7356 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/extra/m_filter_pcre.cpp25
-rw-r--r--src/modules/extra/m_httpclienttest.cpp23
-rw-r--r--src/modules/extra/m_mysql.cpp26
-rw-r--r--src/modules/extra/m_pgsql.cpp23
-rw-r--r--src/modules/extra/m_sqlauth.cpp23
-rw-r--r--src/modules/extra/m_sqlite3.cpp21
-rw-r--r--src/modules/m_spanningtree/main.cpp23
7 files changed, 7 insertions, 157 deletions
diff --git a/src/modules/extra/m_filter_pcre.cpp b/src/modules/extra/m_filter_pcre.cpp
index 194c04816..035d632ca 100644
--- a/src/modules/extra/m_filter_pcre.cpp
+++ b/src/modules/extra/m_filter_pcre.cpp
@@ -177,29 +177,6 @@ class ModuleFilterPCRE : public FilterBase
return 0;
}
};
-
-class ModuleFilterPCREFactory : public ModuleFactory
-{
- public:
- ModuleFilterPCREFactory()
- {
- }
-
- ~ModuleFilterPCREFactory()
- {
- }
-
- virtual Module * CreateModule(InspIRCd* Me)
- {
- return new ModuleFilterPCRE(Me);
- }
-
-};
-
-
-extern "C" DllExport void * init_module( void )
-{
- return new ModuleFilterPCREFactory;
-}
+MODULE_INIT(ModuleFilterPCRE);
diff --git a/src/modules/extra/m_httpclienttest.cpp b/src/modules/extra/m_httpclienttest.cpp
index 5ec097aaf..90e7a5159 100644
--- a/src/modules/extra/m_httpclienttest.cpp
+++ b/src/modules/extra/m_httpclienttest.cpp
@@ -77,26 +77,5 @@ public:
};
-class MyModuleFactory : public ModuleFactory
-{
-public:
- MyModuleFactory()
- {
- }
-
- ~MyModuleFactory()
- {
- }
-
- virtual Module * CreateModule(InspIRCd* Me)
- {
- return new MyModule(Me);
- }
-
-};
-
-extern "C" void * init_module( void )
-{
- return new MyModuleFactory;
-}
+MODULE_INIT(MyModule);
diff --git a/src/modules/extra/m_mysql.cpp b/src/modules/extra/m_mysql.cpp
index 1b83617d6..6605bed3c 100644
--- a/src/modules/extra/m_mysql.cpp
+++ b/src/modules/extra/m_mysql.cpp
@@ -885,29 +885,5 @@ void* DispatcherThread(void* arg)
return NULL;
}
+MODULE_INIT(ModuleSQL);
-// stuff down here is the module-factory stuff. For basic modules you can ignore this.
-
-class ModuleSQLFactory : public ModuleFactory
-{
- public:
- ModuleSQLFactory()
- {
- }
-
- ~ModuleSQLFactory()
- {
- }
-
- virtual Module * CreateModule(InspIRCd* Me)
- {
- return new ModuleSQL(Me);
- }
-
-};
-
-
-extern "C" void * init_module( void )
-{
- return new ModuleSQLFactory;
-}
diff --git a/src/modules/extra/m_pgsql.cpp b/src/modules/extra/m_pgsql.cpp
index 57c049f30..5d267fc1a 100644
--- a/src/modules/extra/m_pgsql.cpp
+++ b/src/modules/extra/m_pgsql.cpp
@@ -980,26 +980,5 @@ void SQLConn::DelayReconnect()
((ModulePgSQL*)us)->ReconnectConn(this);
}
+MODULE_INIT(ModulePgSQL);
-class ModulePgSQLFactory : public ModuleFactory
-{
- public:
- ModulePgSQLFactory()
- {
- }
-
- ~ModulePgSQLFactory()
- {
- }
-
- virtual Module * CreateModule(InspIRCd* Me)
- {
- return new ModulePgSQL(Me);
- }
-};
-
-
-extern "C" void * init_module( void )
-{
- return new ModulePgSQLFactory;
-}
diff --git a/src/modules/extra/m_sqlauth.cpp b/src/modules/extra/m_sqlauth.cpp
index 36dcb0952..6b05ee521 100644
--- a/src/modules/extra/m_sqlauth.cpp
+++ b/src/modules/extra/m_sqlauth.cpp
@@ -190,26 +190,5 @@ public:
};
-class ModuleSQLAuthFactory : public ModuleFactory
-{
- public:
- ModuleSQLAuthFactory()
- {
- }
-
- ~ModuleSQLAuthFactory()
- {
- }
-
- virtual Module * CreateModule(InspIRCd* Me)
- {
- return new ModuleSQLAuth(Me);
- }
-
-};
-
+MODULE_INIT(ModuleSQLAuth);
-extern "C" void * init_module( void )
-{
- return new ModuleSQLAuthFactory;
-}
diff --git a/src/modules/extra/m_sqlite3.cpp b/src/modules/extra/m_sqlite3.cpp
index 88b5aebcd..735591496 100644
--- a/src/modules/extra/m_sqlite3.cpp
+++ b/src/modules/extra/m_sqlite3.cpp
@@ -656,24 +656,5 @@ void ResultNotifier::Dispatch()
((ModuleSQLite3*)mod)->SendQueue();
}
-class ModuleSQLite3Factory : public ModuleFactory
-{
- public:
- ModuleSQLite3Factory()
- {
- }
-
- ~ModuleSQLite3Factory()
- {
- }
+MODULE_INIT(ModuleSQLite3);
- virtual Module * CreateModule(InspIRCd* Me)
- {
- return new ModuleSQLite3(Me);
- }
-};
-
-extern "C" void * init_module( void )
-{
- return new ModuleSQLite3Factory;
-}
diff --git a/src/modules/m_spanningtree/main.cpp b/src/modules/m_spanningtree/main.cpp
index 3fdb26875..97941cb5d 100644
--- a/src/modules/m_spanningtree/main.cpp
+++ b/src/modules/m_spanningtree/main.cpp
@@ -1387,26 +1387,5 @@ Priority ModuleSpanningTree::Prioritize()
return PRIORITY_LAST;
}
-class ModuleSpanningTreeFactory : public ModuleFactory
-{
- public:
- ModuleSpanningTreeFactory()
- {
- }
-
- ~ModuleSpanningTreeFactory()
- {
- }
-
- virtual Module * CreateModule(InspIRCd* Me)
- {
- return new ModuleSpanningTree(Me);
- }
-
-};
+MODULE_INIT(ModuleSpanningTree);
-
-extern "C" DllExport void * init_module( void )
-{
- return new ModuleSpanningTreeFactory;
-}