summaryrefslogtreecommitdiff
path: root/modules.c
diff options
context:
space:
mode:
authorrob rob@31f1291d-b8d6-0310-a050-a5561fc1590b <rob rob@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864>2004-03-31 15:45:28 +0000
committerrob rob@31f1291d-b8d6-0310-a050-a5561fc1590b <rob rob@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864>2004-03-31 15:45:28 +0000
commit14301f6e65ce327360a720a87d9eb55476e2cf66 (patch)
treeb6b2cdb68f0ffbf9d73903d236ed78394bc2b36f /modules.c
parent15d01b86682e5af4ff1ad3a709680740cb5e37fe (diff)
BUILD : 1.7.0 (12) BUGS : 5 NOTES : Fixed a bug with module callbacks, this is a tiny fix, but will need to be merged with the 1.6.x series, as it can cause a segfault if a module attempts to use recersive callbacks.
git-svn-id: svn://svn.anope.org/anope/trunk@12 31f1291d-b8d6-0310-a050-a5561fc1590b git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@7 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'modules.c')
-rw-r--r--modules.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/modules.c b/modules.c
index 031ef7487..0ed7507fc 100644
--- a/modules.c
+++ b/modules.c
@@ -1264,7 +1264,9 @@ void moduleCallBackRun(void)
if (debug)
alog("Executing callback: %s", tmp->name ? tmp->name : "?");
if (tmp->func) {
+ mod_current_module_name = tmp->owner_name;
tmp->func(tmp->argc, tmp->argv);
+ mod_current_module = NULL;
moduleCallBackDeleteEntry(NULL); /* delete the head */
}
}