Article View: news.software.readers
Article #20325Re: TIN - Stopping it from getting all articles
From: billy
Date: Tue, 02 Apr 1996 00:00
Date: Tue, 02 Apr 1996 00:00
140 lines
5710 bytes
5710 bytes
;\tcpip\usr\support <frickson@guenon.gibbon.com> writes:
> TIN always gets all available articles when you enter a group, I guess so
> it can show the thread history.
So it can sort everything properly, yes.
> For active newsgroups, this can take a
> *LONG* time.
You must be using it over the phone...
> I wouldn't think I should have to wait for the
> headers of 5000+ articles to be loaded before I can see the 50 new messages
> posted to a group.
You don't have to, but then if you want to see old articles
they won't be there either. This is the trade-off..
> Is there any way to stop it from doing that, and retrieving the information
> for unread articles?
See below.
Billy Y..
>From: keithr@primenet.com (Keith Rowland)
Newsgroups: primenet.help.slip.linux
Subject: TIN mod for SLIP Users
Date: 14 Jun 1995 03:27:52 GMT
Organization: Southwest Software
======================================================
TIN Modifications for Speeding up SLIP NNTP Users
======================================================
By Keith Rowland <keithr@primenet.com> June 13, 1995
======================================================
Patching tin V1.3 BETA
Modifications to the tin newsreader to restrict the reading of
groups to NEW subject only. This helps reduce the traffic over your
SLIP connection and speed up display of new articles. Instead of
reading the entire index for each group over a slow 14.4Kbps SLIP
connection, this modification, instructs tin to ONLY read articles
starting with the number of the last read article number in your
local .newsrc.
You need to edit three source code files. One header and two .c files.
The make will re-buld all modules, since the header file changes.
I do not claim that this is the best fix nor claim to be an expert
in tin, so if anyone has a cleaner or better patch I am open for
suggestions.
1. First declare a new item in the newsrc structure.
================================================================
In file: .../include/tin.h
In define: struct t_newsrc
Look for:
================================================================
struct t_newsrc
{
int update; /* update newsrc ? */
long num_unread; /* unread articles in group */
long xmax; /* newsrc max */
long xmin; /* newsrc min */
================================================================
Add this:
================================================================
long klr; /* Keep Last Read */
================================================================
2. Tell the newsrc reading routine to save the last message read
number in the structure. This takes the second number of the first
range of read messages. If there are other ranges, they are ignored
for the purpose of this patch. We still need to read some un-read,
so only the first range is needed.
================================================================
In file: ...src/newsrc.c
In routine: parse_bitmap_seq (group, seq)
Find this:
================================================================
debug_print_comment(buf);
debug_print_bitmap(group,NULL);
}
#endif
if (*ptr) {
gotseq = TRUE;
ptr = pcParseGetSeq (ptr, &low, &high);
if (high < group->xmin - 1) {
high = group->xmin - 1;
}
if (high > group->xmax) {
high = group->xmax;
}
================================================================
Add this line:
================================================================
group->newsrc.klr = high; /* Save last read article */
================================================================
3. Now we have the actual 'get subjects' routine use this last read
article number for requests to the NNTP server, instead of the very
first article in the newsreaders active file. This only requests
the unread portion of the article list.
================================================================
In file: ...src/art.c
In routine: index_group (group)
Find this:
================================================================
debug_print_comment ("Before iReadNovFile");
debug_print_bitmap (group, NULL);
min = top_base ? base[0] : group->xmin;
max = top_base ? base[top_base-1] : min - 1;
================================================================
Add this line:
================================================================
min = group->newsrc.klr ; /* last read */
==================================================================
Now just 'make <your_os>' in the .../src directory.
These patches were performed on the 1.3 BETA release. I am sure you
can find the same places in the current 1.2 release.
I have not produced a actual diff file yet, until the 1.3 release
is final. I will also offer this up to be a command line option to
Iain Lee.
Inquiries regarding this patch should be sent to keithr@primenet.com
---------- EOF ----------
Best Regards, Keith in Mesa, Arizona
Technical Details
Message-ID:
<4jr4tt$mpe@nnrp1.news.primenet.com>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.mbox.zip!not-for-mailReferences:
<4jr2gk$aad@blackice.winternet.com>Show Full Headers
Complete Article Headers
Message-ID: <4jr4tt$mpe@nnrp1.news.primenet.com> Subject: Re: TIN - Stopping it from getting all articles Date: Tue, 02 Apr 1996 00:00:00 +0000 From: billy@mix.com References: <4jr2gk$aad@blackice.winternet.com> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.mbox.zip!not-for-mail X-Deja-AN: 145410412 Sender: root@primenet.com Organization: Billy's Place X-posted-by: billy@usr6.primenet.com Newsgroups: news.software.readers