diff options
author | Adam <Adam@anope.org> | 2010-10-02 21:09:11 -0400 |
---|---|---|
committer | Adam <Adam@anope.org> | 2010-10-02 21:09:11 -0400 |
commit | 90f0a7c92ac34bc70c0905c20aaf3f7e8a85f289 (patch) | |
tree | a2bf75cc912ed3803157d10761dbea2c2475ffb1 /include | |
parent | 0d684191e99a689c80560018dd52e6d8fd5dc549 (diff) |
Added os_modreload. Also allow unloading database and encryption modules since there isn't a reason we cant allow reloading them. Soon os_modreload will allow reloading the protocol modules.
Diffstat (limited to 'include')
-rw-r--r-- | include/language.h | 4 | ||||
-rw-r--r-- | include/modules.h | 8 |
2 files changed, 9 insertions, 3 deletions
diff --git a/include/language.h b/include/language.h index 79e082ebf..a9a88bdde 100644 --- a/include/language.h +++ b/include/language.h @@ -1121,6 +1121,7 @@ enum LanguageString DEFCON_GLOBAL, OPER_MODULE_LOADED, OPER_MODULE_UNLOADED, + OPER_MODULE_RELOADED, OPER_MODULE_LOAD_FAIL, OPER_MODULE_REMOVE_FAIL, OPER_MODULE_NO_UNLOAD, @@ -1128,6 +1129,7 @@ enum LanguageString OPER_MODULE_ISNT_LOADED, OPER_MODULE_LOAD_SYNTAX, OPER_MODULE_UNLOAD_SYNTAX, + OPER_MODULE_RELOAD_SYNTAX, OPER_MODULE_LIST_HEADER, OPER_MODULE_LIST, OPER_MODULE_LIST_FOOTER, @@ -1514,6 +1516,7 @@ enum LanguageString OPER_HELP_CMD_SVSNICK, OPER_HELP_CMD_MODLOAD, OPER_HELP_CMD_MODUNLOAD, + OPER_HELP_CMD_MODRELOAD, OPER_HELP_CMD_MODINFO, OPER_HELP_CMD_MODLIST, OPER_HELP, @@ -1550,6 +1553,7 @@ enum LanguageString OPER_HELP_USERLIST, OPER_HELP_MODLOAD, OPER_HELP_MODUNLOAD, + OPER_HELP_MODRELOAD, OPER_HELP_MODINFO, OPER_HELP_MODLIST, BOT_HELP_CMD_BOTLIST, diff --git a/include/modules.h b/include/modules.h index ab3472132..a48e7385f 100644 --- a/include/modules.h +++ b/include/modules.h @@ -148,7 +148,9 @@ enum ModuleReturn MOD_ERR_UNKNOWN, MOD_ERR_FILE_IO, MOD_ERR_NOSERVICE, - MOD_ERR_NO_MOD_NAME + MOD_ERR_NO_MOD_NAME, + MOD_ERR_EXCEPTION, + MOD_ERR_VERSION }; /** Priority types which can be returned from Module::Prioritize() @@ -1106,14 +1108,14 @@ class CoreExport ModuleManager * @param u the user who loaded it, NULL for auto-load * @return MOD_ERR_OK on success, anything else on fail */ - static int LoadModule(const Anope::string &modname, User *u); + static ModuleReturn LoadModule(const Anope::string &modname, User *u); /** Unload the given module. * @param m the module to unload * @param u the user who unloaded it * @return MOD_ERR_OK on success, anything else on fail */ - static int UnloadModule(Module *m, User * u); + static ModuleReturn UnloadModule(Module *m, User * u); /** Change the priority of one event in a module. * Each module event has a list of modules which are attached to that event type. If you wish to be called before or after other specific modules, you may use this |