]> arthur.barton.de Git - ngircd-alex.git/commitdiff
Enhance INFO command to report compile time, if available
authorAlexander Barton <alex@barton.de>
Thu, 5 Mar 2009 15:04:36 +0000 (16:04 +0100)
committerAlexander Barton <alex@barton.de>
Thu, 5 Mar 2009 15:04:36 +0000 (16:04 +0100)
ChangeLog
src/ngircd/irc-info.c

index 38fb7f2ff6a4574b75a9935704b1dd18a0a6d334..e0d13652393283c93bde5228c8a88844949d829b 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -12,6 +12,7 @@
 
 ngIRCd Release 14~rc1
 
+  - The INFO command reports the compile time now (if available).
   - Spell check and enhance ngIRCd manual pages.
   - Channel mode changes: break on syntax errors in MODE command.
   - Support individual channel keys for pre-defined channels: introduce
index 4ac2a47857088ccf6eb269dc3181b3274418d49f..e9345217c5c353e2608d2b3f7ba62e6bdb4b60e3 100644 (file)
@@ -133,8 +133,14 @@ IRC_INFO(CLIENT * Client, REQUEST * Req)
        if (!IRC_WriteStrClient(Client, RPL_INFO_MSG, Client_ID(prefix),
                                NGIRCd_Version))
                return DISCONNECTED;
-       
-       strlcpy(msg, "Server has been started ", sizeof(msg));
+
+#if defined(__DATE__) && defined(__TIME__)
+       snprintf(msg, sizeof(msg), "Birth Date: %s at %s", __DATE__, __TIME__);
+       if (!IRC_WriteStrClient(Client, RPL_INFO_MSG, Client_ID(prefix), msg))
+               return DISCONNECTED;
+#endif
+
+       strlcpy(msg, "On-line since ", sizeof(msg));
        strlcat(msg, NGIRCd_StartStr, sizeof(msg));
        if (!IRC_WriteStrClient(Client, RPL_INFO_MSG, Client_ID(prefix), msg))
                return DISCONNECTED;