summaryrefslogtreecommitdiff
path: root/src/modules.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2005-05-29 15:54:21 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2005-05-29 15:54:21 +0000
commit092c202a5e64852d38b3157c0d8c7b51b866a7f2 (patch)
tree238c8b9c38549fe88c68c166f911bd753b501bd5 /src/modules.cpp
parentef70e0ac9cd103adcfc1b879c0a6c946fd53413b (diff)
Added include stack to detect looped includes
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@1553 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules.cpp')
-rw-r--r--src/modules.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/modules.cpp b/src/modules.cpp
index 14b2abb3e..964cd2b74 100644
--- a/src/modules.cpp
+++ b/src/modules.cpp
@@ -72,6 +72,8 @@ extern int MODCOUNT;
extern std::vector<Module*> modules;
extern std::vector<ircd_module*> factory;
+extern std::vector<std::string> include_stack;
+
extern time_t TIME;
extern int LogLevel;
@@ -818,6 +820,7 @@ Module* Server::FindModule(std::string name)
ConfigReader::ConfigReader()
{
+ include_stack.clear();
this->cache = new std::stringstream(std::stringstream::in | std::stringstream::out);
this->errorlog = new std::stringstream(std::stringstream::in | std::stringstream::out);
this->readerror = LoadConf(CONFIG_FILE,this->cache,this->errorlog);