W3C home > Mailing lists > Public > www-lib@w3.org > July to September 2000

Re: problem in HTCache.c

From: <jose.kahan@w3.org>
Date: Tue, 8 Aug 2000 17:13:27 +0200 (MET DST)
Message-Id: <200008081513.RAA05426@tuvalu.inrialpes.fr>
To: Jens Meggers <jens@meggers.com>
CC: www-lib@w3.org
Hello Jens,

Thanks for your patches. I just committed it to CVS.
I made a small change to avoid duplicating the if condition:

 if ((pres->freshness_lifetime < current_age)
	&& HTCache_remove (pres)) {
     cur = old_cur;
 } else {
     old_cur = cur;

And something similar in the other case.


In our previous episode, Jens Meggers said:
> I found a problem in HTCacheGarbage() of HTCache.c.
> The procedure walks through the cache entires. When an entry is expired, it deletes the object with HTCache_remove(pres) and sets the cur pointer to the former valid pointer by calling cur = old_cur;
> However, if HTCache_remove(pres) does not succeed, we are going into an endless loop. In my implementation this happens because a cache entry was locked. I assume that locked entires cannot be deleted, so I changed the code to the following:
Received on Tuesday, 8 August 2000 11:13:30 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:33:53 UTC