1
0
mirror of https://github.com/anope/anope.git synced 2026-06-27 17:06:39 +02:00

Rewrote part of the Timer and CallBack code for modules to be sane

git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@2795 5417fbe8-f217-4b02-8779-1006273d7864
This commit is contained in:
Adam-
2010-02-25 06:20:00 +00:00
parent 54a60add71
commit 235c4ae95c
9 changed files with 46 additions and 115 deletions
+5 -9
View File
@@ -467,16 +467,12 @@ bool ModuleManager::SetPriority(Module* mod, Implementation i, Priority s, Modul
return true;
}
/** Delete all timers attached to a module
/** Delete all callbacks attached to a module
* @param m The module
*/
void ModuleManager::ClearTimers(Module *m)
void ModuleManager::ClearCallBacks(Module *m)
{
std::list<Timer *>::iterator it;
for (it = m->CallBacks.begin(); it != m->CallBacks.end(); ++it)
{
TimerManager::DelTimer(*it);
}
m->CallBacks.clear();
while (!m->CallBacks.empty())
delete m->CallBacks.front();
}