Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!cmcl2!rutgers!sunybcs!boulder!fesk!sverre From: sverre@fesk.UUCP (Sverre Froyen) Newsgroups: news.software.b Subject: Re: Patch 11 breaks expire Message-ID: <153@fesk.UUCP> Date: Wed, 21-Oct-87 12:45:37 EDT Article-I.D.: fesk.153 Posted: Wed Oct 21 12:45:37 1987 Date-Received: Sat, 24-Oct-87 04:24:29 EDT References: <3070@imt3b2.UUCP> Organization: SERI, Golden, CO Lines: 75 in article <3070@imt3b2.UUCP>, imtsft@imt3b2.UUCP (IMT) says: > Come on folks! How about testing the patches to usenet software BEFORE they > go out. Patch 11 broke expire on systems that do not have dbm and use the > history file (as is the normal case) for expiring articles. Expire builds > a NARTFILE during the expiration process and then attempts to read the > ARTFILE to rebuild the history subfiles. This ONLY works when an ARTFILE > exists. The result is that a message indicating a non existing file > (/usr/lib/news/history) is produced and your current history (history.d/*) > is gone (all zero length files). Prior to Patch 11, the NARTFILE was > renamed to ARTFILE before the rebuild. Patch 11 took it out. > This puts it back in..... I think that you will find it is still broken: expire -r will likely fail. Patch 10 introduced changes appearently in an effort to use the file `history' as a scratch file rather than `nhistory' (ARTFILE and NARTFILE above). The patch below completes this change. *** save/expire.c Mon Oct 19 08:49:07 1987 --- expire.c Wed Oct 21 09:45:43 1987 *************** *** 361,366 } else { #ifdef DBM ohfd = xfopen(ARTFILE, "r"); #else ohfd = nexthistfile((FILE *)NULL); #endif /* DBM */ --- 361,367 ----- } else { #ifdef DBM ohfd = xfopen(ARTFILE, "r"); + nhfd = xfopen(NARTFILE, "w"); #else ohfd = nexthistfile((FILE *)NULL); nhfd = xfopen(ARTFILE, "w"); *************** *** 363,368 ohfd = xfopen(ARTFILE, "r"); #else ohfd = nexthistfile((FILE *)NULL); #endif /* DBM */ nhfd = xfopen(NARTFILE, "w"); } --- 364,370 ----- nhfd = xfopen(NARTFILE, "w"); #else ohfd = nexthistfile((FILE *)NULL); + nhfd = xfopen(ARTFILE, "w"); #endif /* DBM */ } *************** *** 364,370 #else ohfd = nexthistfile((FILE *)NULL); #endif /* DBM */ - nhfd = xfopen(NARTFILE, "w"); } dolock(); --- 366,371 ----- ohfd = nexthistfile((FILE *)NULL); nhfd = xfopen(ARTFILE, "w"); #endif /* DBM */ } dolock(); -- Sverre Froyen UUCP: boulder!fesk!sverre, sunpeaks!seri!fesk!sverre ARPA: froyen@nmfecc.arpa BITNET: froyen@csugold.bitnet