X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fmodmanager_dynamic.cpp;h=9a687ad2bf1af38002134ff30aefc3f288ff6603;hb=b9c6792cd6123d9c6c0c30df75b0afe09258376f;hp=fc6161e3175f2320d22e331bd3d52c22a6369295;hpb=6fe1f4e1136f2ab95a88e68af1894bf6002d03f4;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/modmanager_dynamic.cpp b/src/modmanager_dynamic.cpp index fc6161e31..9a687ad2b 100644 --- a/src/modmanager_dynamic.cpp +++ b/src/modmanager_dynamic.cpp @@ -27,15 +27,16 @@ #ifndef PURE_STATIC -bool ModuleManager::Load(const std::string& filename, bool defer) +bool ModuleManager::Load(const std::string& modname, bool defer) { /* Don't allow people to specify paths for modules, it doesn't work as expected */ - if (filename.find('/') != std::string::npos) + if (modname.find('/') != std::string::npos) { - LastModuleError = "You can't load modules with a path: " + filename; + LastModuleError = "You can't load modules with a path: " + modname; return false; } + const std::string filename = ExpandModName(modname); const std::string moduleFile = ServerInstance->Config->Paths.PrependModule(filename); if (!FileSystem::FileExists(moduleFile))