[net.news.b] Bug in expire.c that affects Pyramids

clewis@mnetor.UUCP (Chris Lewis) (05/21/85)

On "news 2.10.2" after a news system blowup (multiple concurrent expires) 
totally trashed our active and history file (zero contents) we attempted
to rebuild active and history via "expire -r".  There was an immediate
core dump.  Looking through the source I discovered that there was
the following declaration in expire.c fcn. "main":

	DIR *ngdirp;

And, later, there was a test to see if it was non-null - if it was,
a "closedir" was issued on it.  Apparently we got bitten by the
"Pyramid-really-initializes-local-variables-to-garbage" characteristic.
I thought VAXen BSD's did this too, but I guess not in this case.
Anyhow, the fix that worked was:

	DIR *ngdirp = (DIR *) NULL;

"expire -r" worked fine from then on.
-- 
Chris Lewis,
UUCP: {allegra, linus, ihnp4}!utzoo!mnetor!clewis
BELL: (416)-475-8980 ext. 321

greg@ncr-tp.UUCP (Greg Noel) (05/28/85)

In article <843@mnetor.UUCP> clewis@mnetor.UUCP (Chris Lewis) submits
a fix to expire.c.  On our Pyramid, expire works OK (I think), but gets
a lot of strange "cannot find all links" messages.  I checked his problem
and it has already been fixed in our version (last modified Sep 12, 1984,
so it's not recent).  OK, since this wasn't the problem, can somebody
explain the "cannot find all links" message?  \I/ seem to be able to find
all the links........
-- 
-- Greg Noel, NCR Torrey Pines       Greg@ncr-tp.UUCP or Greg@nosc.ARPA

chuqui@nsc.UUCP (Chuq Von Rospach) (05/31/85)

In article <216@ncr-tp.UUCP> greg@ncr-tp.UUCP (Greg Noel) writes:
>a lot of strange "cannot find all links" messages.  I checked his problem

that isn't a bug, that is a feature. When you use 'expire -r' command
expire will traverse your SPOOl directory and read the header of every
file. The then attempts to coordinate the Newsgroups: lines where multiple
groups have been posted to so that a single line can be written to the
history file. When you get a message that has been posted to multiple
groups and one of those groups isn't supported on your site (for example,
if the posting is to 'net.wanted,nj.wanted' and your site is in the bay
area) then the second link won't exist and expire will report it as
missing. With 2.10.1 news, expire didn't write ANY of the links in,
sometimes rebuilding a database that was worse than it started with (sigh).
2.10.2 is much better, and will write the correct line to the data file, so
these messages can be ignored safely (and, if you get annoyed at them, can
be hacked out of the program... hint. hint).

chuq
-- 
:From the misfiring synapses of:                  Chuq Von Rospach
{cbosgd,fortune,hplabs,ihnp4,seismo}!nsc!chuqui   nsc!chuqui@decwrl.ARPA

This space for rent. Political, religious and racist quotes need not apply.

sml@luke.UUCP (Steven List) (06/02/85)

> In article <216@ncr-tp.UUCP> greg@ncr-tp.UUCP (Greg Noel) writes:
> >a lot of strange "cannot find all links" messages.  I checked his problem
> 
> that isn't a bug, that is a feature. When you use 'expire -r' command
> expire will traverse your SPOOl directory and read the header of every

I just looked at my 2.10.2 B expire(1) page.  It makes not mention of a
`-r' option.  In making a quick pass at the code, it is clear that the
manual page is not in sync with the program.  Does someone out there
have the current version?  If so, would you mail it to me?

Thanks.