🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: demon.ip.developers
Article #897

[Snews/Unbatch] Minor bug in Path: handling

#897
From: Graham E Kinns
Date: Wed, 17 Jul 1996 00:00
24 lines
1380 bytes
If whitespace appears in the Path: line, Unbatch terminates the line 
there, unfortunately chopping off the \n which means the following 
header field gets appended to the same line after writing the article 
to the newsbase.  Snews obviously fails to read the header correctly 
after this corruption has taken place.

<4rpar3$97m@genesis.DOMINO.ORG> (d.s:31909 on news.d.c.u) is one of 
several that demonstrates this.

unbatch.c, in toss() starting at line #884 (v1.30):

    	/* add our system name to the path list */
    	if (strnicmp(buf, "Path:", 5) == 0) {
    		p = strtok(buf, " \t");
887:		p = strtok(NULL, " \t");
    		sprintf(buf2, "Path: %s.%s!%s", my_stuff.my_site,
    		        my_stuff.my_domain, p);

Replacing " \t" with "" in the second strtok() line 887 fixes this.

Cheers, Graham.
-- 
----[ Graham E. Kinns ]----==========----< Graham@grempc.demon.co.uk >----
Technical Details
Message-ID: <837637586snz.4856@grempc.demon.co.uk>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10bb05,8de5d7c512924b4e,start
X-Google-Attributes: gid10bb05,public
From: Graham E Kinns <Graham@grempc.demon.co.uk>
Subject: [Snews/Unbatch] Minor bug in Path: handling
Date: 1996/07/17
Message-ID: <837637586snz.4856@grempc.demon.co.uk>
X-Deja-AN: 168636454
x-mail2news-path: grempc.demon.co.uk
x-nntp-posting-host: grempc.demon.co.uk
organization: Home, N Yorks, UK
newsgroups: demon.ip.developers