INN commit: trunk/nnrpd (list.c)

INN Commit Russ_Allbery at isc.org
Mon Sep 22 18:50:21 UTC 2008


    Date: Monday, September 22, 2008 @ 11:50:21
  Author: iulius
Revision: 8047

Use "n" instead of "j" and "x" for active newsgroups flags.
It is more useful for readers.

Modified:
  trunk/nnrpd/list.c

--------+
 list.c |   13 +++++++++++++
 1 file changed, 13 insertions(+)

Modified: list.c
===================================================================
--- list.c	2008-09-21 19:05:53 UTC (rev 8046)
+++ list.c	2008-09-22 18:50:21 UTC (rev 8047)
@@ -185,6 +185,9 @@
             return false;
     }
     if (OVgroupstats(group, &lo, &hi, NULL, &flag) && flag != '=') {
+        /* Convert flags to standardized ones, if possible. */
+        if (flag == 'j' || flag == 'x')
+            flag = 'n';
         Reply("%d %s\r\n", NNTP_OK_LIST, INFOactive.Format);
         Printf("%s %010u %010u %c\r\n", group, hi, lo, flag);
         Printf(".\r\n");
@@ -342,8 +345,18 @@
          * if given. */
 	if (wildarg && !uwildmat(p, wildarg))
 	    continue;
+
 	if (savec != '\0')
 	    *save = savec;
+
+        if (lp == &INFOactive) {
+            /* Convert flags to standardized ones, if possible. */
+            if ((q = strrchr(p, ' ')) != NULL) {
+                q++;
+                if (*q == 'j' || *q == 'x')
+                    *q = 'n';
+            }
+        }
 	Printf("%s\r\n", p);
     }
     QIOclose(qp);



More information about the inn-committers mailing list