summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/modules.h6
-rw-r--r--src/modules.cpp5
2 files changed, 10 insertions, 1 deletions
diff --git a/include/modules.h b/include/modules.h
index 71bec2d3d..2a7525c07 100644
--- a/include/modules.h
+++ b/include/modules.h
@@ -1104,7 +1104,11 @@ class Server : public classbase
* Destroys a Server object.
*/
virtual ~Server();
-
+ /** Obtains a pointer to the server's ServerConfig object.
+ * The ServerConfig object contains most of the configuration data
+ * of the IRC server, as read from the config file by the core.
+ */
+ ServerConfig* GetConfig();
/** Sends text to all opers.
* This method sends a server notice to all opers with the usermode +s.
*/
diff --git a/src/modules.cpp b/src/modules.cpp
index 629672b24..5fef5a608 100644
--- a/src/modules.cpp
+++ b/src/modules.cpp
@@ -329,6 +329,11 @@ void Server::RehashServer()
Config->Read(false,NULL);
}
+ServerConfig* Server::GetConfig()
+{
+ return Config;
+}
+
void Server::DelSocket(InspSocket* sock)
{
for (std::vector<InspSocket*>::iterator a = module_sockets.begin(); a < module_sockets.end(); a++)