race condition issue?
Submitted by Akira TAGOH
Assigned to Akira TAGOH
There seems the kind of the race condition issue when updating the fontconfig cache for directory. it is, somehow the directory cache is missing a directory 'a' when creating a directory, installing a font and generating a cache. That seems most likely to happen when installing OS newly.
I'm not quite sure the details and root-cause but the scenario what I can imagine is:
- installing 'a' font package
- generating a cache for 'a'
- installing 'b' font package at the same time
- generating a cache for 'b'
- somehow updating the parent directory cache from 'b' first
- updating the parent directory cache from 'a'
If there are no 'b' directory when processing 'a', this might happens.
possible some idea to address this situation: a) remember the time when starting to generate the cache and write it into the cache. so if it's newer than one has, they can just stop to proceed.
b) when failed to lock the cache, restart the process from reading the directory
any other idea?