INN commit: trunk (innd/nc.c nnrpd/nnrpd.c)
INN Commit
rra at isc.org
Wed May 14 17:39:56 UTC 2014
Date: Wednesday, May 14, 2014 @ 10:39:56
Author: iulius
Revision: 9630
Recognize the no-op XYZZY keyword
Yep, nothing new happens with that patch.
Modified:
trunk/innd/nc.c
trunk/nnrpd/nnrpd.c
---------------+
innd/nc.c | 7 ++++++-
nnrpd/nnrpd.c | 7 ++++++-
2 files changed, 12 insertions(+), 2 deletions(-)
Modified: innd/nc.c
===================================================================
--- innd/nc.c 2014-05-14 17:23:39 UTC (rev 9629)
+++ innd/nc.c 2014-05-14 17:39:56 UTC (rev 9630)
@@ -1267,7 +1267,12 @@
NCwritereply(cp, buff);
break;
}
- snprintf(buff, sizeof(buff), "%d What?", NNTP_ERR_COMMAND);
+ if (strcasecmp(cp->av[0], "XYZZY") == 0) {
+ /* Acknowledge the magic word from the Colossal Cave Adventure computer game. */
+ snprintf(buff, sizeof(buff), "%d Nothing happens", NNTP_ERR_COMMAND);
+ } else {
+ snprintf(buff, sizeof(buff), "%d What?", NNTP_ERR_COMMAND);
+ }
NCwritereply(cp, buff);
cp->Start = cp->Next;
Modified: nnrpd/nnrpd.c
===================================================================
--- nnrpd/nnrpd.c 2014-05-14 17:23:39 UTC (rev 9629)
+++ nnrpd/nnrpd.c 2014-05-14 17:39:56 UTC (rev 9630)
@@ -1410,7 +1410,12 @@
syslog(L_NOTICE, "%s unrecognized %.40s...", Client.host, buff);
else
syslog(L_NOTICE, "%s unrecognized %s", Client.host, buff);
- Reply("%d What?\r\n", NNTP_ERR_COMMAND);
+ if (strcasecmp(av[0], "XYZZY") == 0) {
+ /* Acknowledge the magic word from the Colossal Cave Adventure computer game. */
+ Reply("%d Nothing happens\r\n", NNTP_ERR_COMMAND);
+ } else {
+ Reply("%d What?\r\n", NNTP_ERR_COMMAND);
+ }
continue;
}
More information about the inn-committers
mailing list