1
0
mirror of https://github.com/anope/anope.git synced 2026-06-29 19:36:37 +02:00

Added Anope::CurTime to keep us from calling time() everywhere

This commit is contained in:
Adam
2010-09-10 20:31:31 -04:00
parent 9eb7562bee
commit f00e76d30a
64 changed files with 224 additions and 240 deletions
+1 -1
View File
@@ -130,7 +130,7 @@ class CommandOSStats : public Command
CommandReturn DoStatsUptime(User *u)
{
char timebuf[64];
time_t uptime = time(NULL) - start_time;
time_t uptime = Anope::CurTime - start_time;
int days = uptime / 86400, hours = (uptime / 3600) % 24, mins = (uptime / 60) % 60, secs = uptime % 60;
notice_lang(Config->s_OperServ, u, OPER_STATS_CURRENT_USERS, usercnt, opcnt);
struct tm *tm = localtime(&maxusertime);