diff options
author | attilamolnar <attilamolnar@hush.com> | 2013-08-16 12:10:55 +0200 |
---|---|---|
committer | attilamolnar <attilamolnar@hush.com> | 2013-08-30 13:15:10 +0200 |
commit | c202dea024542b9c6c6b771bb9a3a081d9eacdc5 (patch) | |
tree | 64f4d5f5c18e685d3cd360107664eec644d5585d /src/modmanager_static.cpp | |
parent | 1031f333332cf1b09db4fd632f141143ee637c34 (diff) |
Replace OnRehash() with ReadConfig() that is called on boot, on module load and on rehash
This eliminates the need for calling OnRehash() in init()
Diffstat (limited to 'src/modmanager_static.cpp')
-rw-r--r-- | src/modmanager_static.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/modmanager_static.cpp b/src/modmanager_static.cpp index 321bf520d..eeb8b6f96 100644 --- a/src/modmanager_static.cpp +++ b/src/modmanager_static.cpp @@ -102,8 +102,11 @@ bool ModuleManager::Load(const std::string& name, bool defer) } else { + ConfigStatus confstatus; + AttachAll(mod); mod->init(); + mod->ReadConfig(confstatus); } } catch (CoreException& modexcept) @@ -203,6 +206,8 @@ void ModuleManager::LoadAll() } } + ConfigStatus confstatus; + for(std::map<std::string, Module*>::iterator i = Modules.begin(); i != Modules.end(); i++) { Module* mod = i->second; @@ -210,6 +215,7 @@ void ModuleManager::LoadAll() { AttachAll(mod); mod->init(); + mod->ReadConfig(confstatus); } catch (CoreException& modexcept) { |