PATCH: fix broken expire due to Caputo's last hisv6 patch
Chris Caputo
ccaputo at alt.net
Wed Jun 15 17:18:00 UTC 2005
On Wed, 15 Jun 2005, Chris Caputo wrote:
> On Mon, 13 Jun 2005, Russ Allbery wrote:
>> Christiaan den Besten <chris at prolocation.net> writes:
>>> Hi Rusty,
>>
>> Rusty? :)
>>
>>> Using the -current of June the 9th wasn't working very well. I noticed
>>> today it had not been expiring any headers anymore since the update. A
>>> downgrade to 2.4.2 made me able to expire again.....
>>
>>> Is there any known upgrade-path to be followed, or is something broken?
>>
>> There shouldn't be any upgrade path needed. Are you sure there are no
>> error messages in syslog? I'm not aware of anything that would have
>> broken expiration.
>
> Ack!!! I broke this with my last patch to hisv6_reopen(). It seems
> HIS_CREAT isn't being set for "history.n" during expire. Researching fix
> now...
Ok. Here's a fix! (Set HIS_CREAT flag so that "w" is used in
hisv6_reopen()'s fopen() of "history.n" rather than "r+".)
Thanks,
Chris
--- history/hisv6/hisv6.c.050615 2005-06-15 16:59:03.000000000 +0000
+++ history/hisv6/hisv6.c 2005-06-15 17:01:16.000000000 +0000
@@ -1321,7 +1321,9 @@ hisv6_expire(void *history, const char *
nhistory = concat(h->histpath, ".n", NULL);
}
- hnew = hisv6_new(nhistory, HIS_RDWR | HIS_INCORE, h->history);
+ hnew = hisv6_new(nhistory,
+ HIS_CREAT | HIS_RDWR | HIS_INCORE,
+ h->history);
if (!hisv6_reopen(hnew)) {
hisv6_dispose(hnew);
hnew = NULL;
More information about the inn-workers
mailing list