🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nntp
1 messages
1 total messages Started by Steve Wyles Sat, 20 May 2000 00:00
diablo Xref generation for control msgs (patch)
#46529
Author: Steve Wyles
Date: Sat, 20 May 2000 00:00
56 lines
2546 bytes
Guys,

	Unfortunately it seems that Xref header generation for control
messages is still broken in diablo-2.0-STABLE-20000517-01 and the previous
snapshot. This becomes very apparent if you are using diablo to assign
article numbers (active on), feeding INN reader machines in xrefslave
mode.

	I thought this had already been fixed in diablo-2.0-REL, but it
appears that somewhere it has been missed out of the later snapshots. The
patch below (I've submitted this before) fixes the problem.

--- active.c.old	Thu May 11 12:11:06 2000
+++ active.c	Thu May 11 12:19:49 2000
@@ -59,7 +59,14 @@
 	    group[i] = 0;
 	    rec = KPDBReadRecord(DActiveDB, group, KP_LOCK, &recLen);
 
-	    if (rec != NULL) {
+/*      Control messages are special, Xref header is still required, but  */
+/*      must only contain control.* groups. Therefore, for non control    */
+/*      messages, process as normal. But, only the control group is put   */
+/*      in the Xref for control messages.                                 */
+
+                if ((rec != NULL && !ctl[0])
+         || (rec != NULL && ctl[0] && (strncmp("control",group,7) == 0)))
+		{
 		int f1len;
 		int f2len;
 		const char *f1 = KPDBGetField(rec, recLen, "NE", &f1len, NULL);
@@ -85,7 +92,14 @@
 		} else {
 		    KPDBUnlock(DActiveDB, rec);
 		}
-	    }
+
+/*      Now catch the non control groups that were listed for a control  */
+/*      message and unlock the active file.                              */
+
+	    } else if (rec != NULL && ctl[0]) {
+                        ++count;
+                        KPDBUnlock(DActiveDB, rec);
+                    }
 	}
 	p += i;
 	if (*p != ',')


Steve

-- 
Steve Wyles
Senior UNIX Systems Administrator
GTS Netcom

Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads