mirror of
https://github.com/anope/anope.git
synced 2026-07-09 07:23:14 +02:00
Added Anope::CurTime to keep us from calling time() everywhere
This commit is contained in:
@@ -164,11 +164,9 @@ class OSIgnore : public Module
|
||||
|
||||
void OnDatabaseWrite(void (*Write)(const Anope::string &))
|
||||
{
|
||||
time_t now = time(NULL);
|
||||
|
||||
for (std::list<IgnoreData *>::iterator ign = ignore.begin(), ign_end = ignore.end(); ign != ign_end; )
|
||||
{
|
||||
if ((*ign)->time && (*ign)->time <= now)
|
||||
if ((*ign)->time && (*ign)->time <= Anope::CurTime)
|
||||
{
|
||||
Log(LOG_DEBUG) << "[os_ignore] Expiring ignore entry " << (*ign)->mask;
|
||||
delete *ign;
|
||||
|
||||
Reference in New Issue
Block a user