]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_alltime.cpp
Remove some debug (im on a crusade to make debug mode useful, but at the same time...
[user/henk/code/inspircd.git] / src / modules / m_alltime.cpp
index 0ce517886d707318e00b56b3ca8c93826ac2fa43..81a3fbf399e73ff311486ef4bd02d0022bc42086 100644 (file)
@@ -1,6 +1,15 @@
-/* Written by Special (john@yarbbles.com) */
-
-using namespace std;
+/*       +------------------------------------+
+ *       | Inspire Internet Relay Chat Daemon |
+ *       +------------------------------------+
+ *
+ *  InspIRCd: (C) 2002-2007 InspIRCd Development Team
+ * See: http://www.inspircd.org/wiki/index.php/Credits
+ *
+ * This program is free but copyrighted software; see
+ *            the file COPYING for details.
+ *
+ * ---------------------------------------------------
+ */
 
 #include <stdio.h>
 #include <string>
@@ -24,8 +33,7 @@ class cmd_alltime : public command_t
                time_t now = ServerInstance->Time();
                strftime(fmtdate, sizeof(fmtdate), "%F %T", gmtime(&now));
                
-               // I'm too lazy to add a function to fetch the delta, so lets just cheat..
-               int delta = time(NULL) - now;
+               int delta = ServerInstance->GetTimeDelta();
                
                string msg = ":" + string(ServerInstance->Config->ServerName) + " NOTICE " + user->nick + " :Time for " +
                        ServerInstance->Config->ServerName + " is: " + fmtdate + " (delta " + ConvToStr(delta) + " seconds)";