[rfc][icedtea-web] clean Cache

Omair Majid omajid at redhat.com
Fri Aug 29 20:45:44 UTC 2014


* Jie Kang <jkang at redhat.com> [2014-08-29 16:28]:
> For background: Right now files can be marked for delete in cache and
> when itw ends, it cleans the cache, removing invalid items and also
> items that are marked for delete. However, there is a bug in this
> function where duplicate items get marked for delete correctly and are
> removed from the LRU file, but don't actually get deleted from the
> file system thus leaving things in the cache that can't be used. The
> patch puts priority on delete by swapping the order of the check and
> fixes the issue.
> 
> Could someone else double-check it?

I read through it, and asked for more explanation of the code and I
still have no idea why this works. More specifically, why is the `if
(keep.contains` conditional needed at all.

Perhaps a set of unit tests will make the behaviour of this code more
obvious?

Thanks,
Omair

-- 
PGP Key: 66484681 (http://pgp.mit.edu/)
Fingerprint = F072 555B 0A17 3957 4E95  0056 F286 F14F 6648 4681


More information about the distro-pkg-dev mailing list