🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.readers
Article #244890

trn bug fix.

#244890
From: David Canzi
Date: Sun, 27 Feb 2011 23:17
105 lines
4285 bytes
Well, *some* people are still using it.

Symptom of bug: new articles in newsgroup marked as unavailable.
Affected articles show up in article tree as "( )".  If you
exit trn and restart it, the affected articles are now visible
but marked as read.

The kill file line

/: 129\.97\.109\.26$/Hnntp-posting-host:j

Would cause trn to mark as unavailable the article *before* any
article without an nntp-posting-host header.  If article 1001
didn't have an nntp-posting-host header, then article 1000 was
marked unavailable.

The order of #include directives in a couple files needed to be
changed in order to compile.

diff -r -c old.trn-4.0-test76/datasrc.c trn-4.0-test76/datasrc.c
*** old.trn-4.0-test76/datasrc.c	Sun Feb 27 17:05:15 2011
--- trn-4.0-test76/datasrc.c	Thu Sep 16 01:08:03 2010
***************
*** 12,19 ****
  #include "nntpclient.h"
  #include "term.h"
  #include "env.h"
- #include "opt.h"
  #include "util.h"
  #include "util2.h"
  #include "intrp.h"
  #include "init.h"
--- 12,19 ----
  #include "nntpclient.h"
  #include "term.h"
  #include "env.h"
  #include "util.h"
+ #include "opt.h"
  #include "util2.h"
  #include "intrp.h"
  #include "init.h"
diff -r -c old.trn-4.0-test76/head.c trn-4.0-test76/head.c
*** old.trn-4.0-test76/head.c	Sun Feb 27 17:05:30 2011
--- trn-4.0-test76/head.c	Mon Sep 27 16:48:38 2010
***************
*** 525,534 ****
  		num = atol(line);
  		if (num < artnum || num > lastnum)
  		    continue;
- 		if (!(datasrc->flags & DF_XHDR_BROKEN)) {
- 		    while ((priornum = article_next(priornum)) < num)
- 			uncache_article(article_ptr(priornum),FALSE);
- 		}
  		ap = article_find(num);
  		if (which_line == SUBJ_LINE)
  		    set_subj_line(ap, t, strlen(t));
--- 525,530 ----
***************
*** 548,557 ****
  	    }
  	    s = fetchlines(artnum,which_line);
  	}
- 	if (hasxhdr && !(datasrc->flags & DF_XHDR_BROKEN)) {
- 	    for (priornum = article_first(priornum); priornum < lastnum; priornum = article_next(priornum))
- 		uncache_article(article_ptr(priornum),FALSE);
- 	}
  	if (copy)
  	    s = saferealloc(s, (MEM_SIZE)strlen(s)+1);
  	return s;
--- 544,549 ----
diff -r -c old.trn-4.0-test76/patchlevel.h trn-4.0-test76/patchlevel.h
*** old.trn-4.0-test76/patchlevel.h	Sun Feb 27 17:05:56 2011
--- trn-4.0-test76/patchlevel.h	Mon Sep 27 17:30:00 2010
***************
*** 1 ****
! #define PATCHLEVEL " 4.0-test76 (Apr 2, 2001)"
--- 1 ----
! #define PATCHLEVEL " 4.0-test76.0001 (Sep 27, 2010)"
diff -r -c old.trn-4.0-test76/rt-page.c trn-4.0-test76/rt-page.c
*** old.trn-4.0-test76/rt-page.c	Sun Feb 27 17:06:12 2011
--- trn-4.0-test76/rt-page.c	Thu Sep 16 01:09:39 2010
***************
*** 14,22 ****
  #include "datasrc.h"
  #include "nntp.h"
  #include "trn.h"
- #include "opt.h"
  #include "env.h"
  #include "util.h"
  #include "util2.h"
  #include "only.h"
  #include "addng.h"
--- 14,22 ----
  #include "datasrc.h"
  #include "nntp.h"
  #include "trn.h"
  #include "env.h"
  #include "util.h"
+ #include "opt.h"
  #include "util2.h"
  #include "only.h"
  #include "addng.h"

-- 
David Canzi		| Life is too short to point out every mistake. |
Technical Details
Message-ID: <ikem1o$15b$1@rumours.uwaterloo.ca>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.20140922.mbox.gz!border1.nntp.dca3.giganews.com!border2.nntp.dca3.giganews.com!border4.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!ctu-peer!news.nctu.edu.tw!meganewsservers.com!feeder2.on.meganewsservers.com!news.uwaterloo.ca!not-for-mail

Show Full Headers
Complete Article Headers
Message-ID: <ikem1o$15b$1@rumours.uwaterloo.ca>
Subject: trn bug fix.
Date: Sun, 27 Feb 2011 23:17:12 +0000
From: dmcanzi@remulak.uwaterloo.ca (David Canzi)
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.20140922.mbox.gz!border1.nntp.dca3.giganews.com!border2.nntp.dca3.giganews.com!border4.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!ctu-peer!news.nctu.edu.tw!meganewsservers.com!feeder2.on.meganewsservers.com!news.uwaterloo.ca!not-for-mail
Newsgroups: news.software.readers
Organization: University of Waterloo
Lines: 105
NNTP-Posting-Host: remulak.uwaterloo.ca
X-Trace: rumours.uwaterloo.ca 1298848632 1195 129.97.109.26 (27 Feb 2011
X-Complaints-To: abuse@uwaterloo.ca
NNTP-Posting-Date: Sun, 27 Feb 2011 23:17:12 +0000 (UTC)
X-Newsreader: trn 4.0-test76.0001 (Sep 27, 2010)
Originator: dmcanzi@remulak.uwaterloo.ca (David Canzi)
X-Original-Bytes: 4080