diff options
Diffstat (limited to 'src/modules.cpp')
-rw-r--r-- | src/modules.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/modules.cpp b/src/modules.cpp index 773f87f66..8c38914e9 100644 --- a/src/modules.cpp +++ b/src/modules.cpp @@ -328,6 +328,10 @@ std::pair<int,std::string> InspIRCd::GetInterfaceInstanceCount(Module* m) const std::string& InspIRCd::GetModuleName(Module* m) { static std::string nothing = ""; /* Prevent compiler warning */ + + if (!this->GetModuleCount()) + return nothing; + for (int i = 0; i <= this->GetModuleCount(); i++) { if (this->modules[i] == m) |