Akira TAGOH <akira@xxxxxxxxx> writes: > As I mentioned in other mail, it was needed to avoid the races. to get > rid of it completely, the logic of the cache updates may needs to be > changed because keeping the directory information into the memory a > long time causes that issue easily when recursively traversing > directories. As long as the timestamp written to the cache is the directory change time when the scanning starts, then applications starting after that will re-scan the directory if it was changed while the first application was scanning. I guess I don't see how this (which is what I think the code does) could cause a race? Alternatively, the library could re-stat the directory after building the cache, and before replacing it in the file system, discarding and rescanning the directory if the timestamp has changed. Write out the cache to a temporary file, check the directory change time and rename the file to the permanent name only if the timestamps were the same. -- -keith
Attachment:
signature.asc
Description: PGP signature
_______________________________________________ Fontconfig mailing list Fontconfig@xxxxxxxxxxxxxxxxxxxxx http://lists.freedesktop.org/mailman/listinfo/fontconfig