INN commit: branches/2.5 (innd/nc.c nnrpd/list.c)

INN Commit rra at isc.org
Sun Nov 15 09:30:28 UTC 2009


    Date: Sunday, November 15, 2009 @ 01:30:28
  Author: iulius
Revision: 8808

Check LIST output for correct dot-stuffing.

Modified:
  branches/2.5/innd/nc.c
  branches/2.5/nnrpd/list.c

--------------+
 innd/nc.c    |    4 ++--
 nnrpd/list.c |    4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

Modified: innd/nc.c
===================================================================
--- innd/nc.c	2009-11-15 09:30:19 UTC (rev 8807)
+++ innd/nc.c	2009-11-15 09:30:28 UTC (rev 8808)
@@ -857,8 +857,8 @@
     /* Loop over all lines, sending the text and "\r\n". */
     while ((p = QIOread(qp)) != NULL) {
         /* Check that the output does not break the NNTP protocol. */
-        if (p[0] == '.' && p[1] == '\0') {
-            syslog(L_ERROR, "%s NClist single dot in file %s",
+        if (p[0] == '.' && p[1] != '.') {
+            syslog(L_ERROR, "%s NClist bad dot-stuffing in file %s",
                    CHANname(cp), cp->av[1]);
             continue;
         }

Modified: nnrpd/list.c
===================================================================
--- nnrpd/list.c	2009-11-15 09:30:19 UTC (rev 8807)
+++ nnrpd/list.c	2009-11-15 09:30:28 UTC (rev 8808)
@@ -256,8 +256,8 @@
     /* Read lines, ignore long ones. */
     while ((p = QIOread(qp)) != NULL) {
         /* Check that the output does not break the NNTP protocol. */
-        if (p[0] == '.' && p[1] == '\0') {
-            syslog(L_ERROR, "%s single dot in %s", Client.host, lp->File);
+        if (p[0] == '.' && p[1] != '.') {
+            syslog(L_ERROR, "%s bad dot-stuffing in %s", Client.host, lp->File);
             continue;
         }
         if (lp == &INFOmotd) {




More information about the inn-committers mailing list