summaryrefslogtreecommitdiff
path: root/src/events.c
diff options
context:
space:
mode:
authorRobin Burchell w00t@inspircd.org <Robin Burchell w00t@inspircd.org@5417fbe8-f217-4b02-8779-1006273d7864>2008-11-06 23:50:03 +0000
committerRobin Burchell w00t@inspircd.org <Robin Burchell w00t@inspircd.org@5417fbe8-f217-4b02-8779-1006273d7864>2008-11-06 23:50:03 +0000
commit9e9ec919ec2e10ae262ec6402f1af3a0171d5444 (patch)
tree22e2e4e1d1d25996bf1697811382d38ada5064a1 /src/events.c
parent4171f140c237f6384ddd55f6015678ef270df7e4 (diff)
Add proper constructor, move Module::name to be string.. still doesn't compile, of course, as this still needs a lot more renovation.
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@1568 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'src/events.c')
-rw-r--r--src/events.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/events.c b/src/events.c
index e7f9b7bce..65338b166 100644
--- a/src/events.c
+++ b/src/events.c
@@ -501,7 +501,7 @@ int moduleAddEventHandler(EvtMessage * evm)
} /* shouldnt happen */
evm->core = 0;
if (!evm->mod_name) {
- evm->mod_name = sstrdup(mod_current_module->name);
+ evm->mod_name = sstrdup(mod_current_module->name.c_str());
}
status = addEventHandler(EVENT, evm);
@@ -534,7 +534,7 @@ int moduleAddEventHook(EvtHook * evh)
} /* shouldnt happen */
evh->core = 0;
if (!evh->mod_name) {
- evh->mod_name = sstrdup(mod_current_module->name);
+ evh->mod_name = sstrdup(mod_current_module->name.c_str());
}
status = addEventHook(EVENTHOOKS, evh);
@@ -562,7 +562,7 @@ int moduleEventDelHandler(char *name)
return MOD_ERR_NOEXIST;
}
- status = delEventHandler(EVENT, evm, mod_current_module->name);
+ status = delEventHandler(EVENT, evm, mod_current_module->name.c_str());
if (debug) {
displayEvtMessageFromHash(evm->name);
}
@@ -587,7 +587,7 @@ int moduleEventDelHook(const char *name)
return MOD_ERR_NOEXIST;
}
- status = delEventHook(EVENTHOOKS, evh, mod_current_module->name);
+ status = delEventHook(EVENTHOOKS, evh, mod_current_module->name.c_str());
if (debug) {
displayHookFromHash(evh->name);
}
@@ -602,7 +602,7 @@ int moduleEventDelHook(const char *name)
* @return MOD_ERR_OK on success, althing else on fail.
**/
int delEventHandler(EvtMessageHash * msgEvtTable[], EvtMessage * evm,
- char *mod_name)
+ const char *mod_name)
{
int index = 0;
EvtMessageHash *current = NULL;
@@ -675,7 +675,7 @@ int delEventHandler(EvtMessageHash * msgEvtTable[], EvtMessage * evm,
* @return MOD_ERR_OK on success, althing else on fail.
**/
int delEventHook(EvtHookHash * hookEvtTable[], EvtHook * evh,
- char *mod_name)
+ const char *mod_name)
{
int index = 0;
EvtHookHash *current = NULL;