*BSD News Article 81057


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.carno.net.au!harbinger.cc.monash.edu.au!munnari.OZ.AU!spool.mu.edu!newspump.sol.net!www.nntp.primenet.com!nntp.primenet.com!news.mathworks.com!fu-berlin.de!irz401!orion.sax.de!uriah.heep!news
From: j@uriah.heep.sax.de (J Wunsch)
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: Re: knews & threads [Was: dummy question]
Date: 18 Oct 1996 23:56:47 GMT
Organization: Private BSD site, Dresden
Lines: 63
Message-ID: <5495fv$c8@uriah.heep.sax.de>
References: <53mfdu$1iv@wa4phy.async.com> <53oncv$fi5@newshost.lanl.gov>
  <53rfcg$a7@anorak.coverform.lan> <5411l8$dr9@uriah.heep.sax.de>
  <542rb6$i6@anorak.coverform.lan>
Reply-To: joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch)
NNTP-Posting-Host: localhost.heep.sax.de
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
X-Newsreader: knews 0.9.6
X-Phone: +49-351-2012 669
X-PGP-Fingerprint: DC 47 E6 E4 FF A6 E9 8F  93 21 E0 7D F9 12 D6 4E

brian@anorak.coverform.lan (Brian Somers) wrote:


> BTW, on another note J"org, I note that you're using knews.  Does this
> article thread correctly after your article in your view ?  Your

Yep.

> previous article mis-threaded (I *think* due to knews on my end) - as
> if knews doesn't handle header line continuations - even though it
> writes them itself.
> 
> This threading lark is beginning to bug me :)

Let me guess... you are running INN, but not overchan?  Then, knews
will use the INN-internal Xover generator.  There's nothing wrong with
this apart from being a little sluggish compared to knews, but i also
prefer this method for my mostly single-user machine.  Alas, there's a
bug in INN.  Below's my fix.  After people have been helping me to
find the current maintainer of INN, i've got a confirmation yesterday
that the fix was accepted for the next version.

--- nnrpd/article.c.orig	Mon Jan  3 17:20:31 1994
+++ nnrpd/article.c	Sun Apr 28 21:50:59 1996
@@ -801,6 +801,22 @@
 	if (*line == '\0')
 	    break;
 
+	/* Is it a continuation line? */
+	if (ISWHITE(*line) && (hp - Headers) < ARTfieldsize) {
+	    /* Skip whitespace but one. */
+	    for (p = line; *p && ISWHITE(*p); p++)
+		continue;
+	    --p;
+	    /* Now append it. */
+	    hp->Length += strlen(p);
+	    RENEW(hp->Header, char, hp->Length + 1);
+	    (void)strcat(hp->Header, p);
+	    for (p = hp->Header; *p; p++)
+		if (*p == '\t' || *p == '\n')
+		    *p = ' ';
+	    continue;
+	}
+
 	/* See if we want this header. */
 	fp = ARTfields;
 	for (hp = Headers, i = ARTfieldsize; --i >= 0; hp++, fp++) {
@@ -833,6 +849,7 @@
 		if (*p == '\t' || *p == '\n')
 		    *p = ' ';
 	    hp->HasHeader = TRUE;
+	    break;
 	}
     }
 


-- 
cheers, J"org

joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ -- NIC: JW11-RIPE
Never trust an operating system you don't have sources for. ;-)