Re: Trouble forcing rescanning of font dirs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> -----Original Message-----
> From: Behdad Esfahbod [mailto:behdad.esfahbod@xxxxxxxxx] On Behalf Of
> Behdad Esfahbod
> Sent: 02 February 2009 13:06
> To: mfabian@xxxxxxx
> Cc: Diego Santa Cruz; fontconfig@xxxxxxxxxxxxxxxxxxxxx
> Subject: Re:  Trouble forcing rescanning of font dirs
> 
> Mike FABIAN wrote:
> > I also think this is a bug, see
> >
> > https://bugzilla.novell.com/show_bug.cgi?id=438855#c23
> >
> > Comment #24 of this bug has a patch which I attach here as well
> > for convenience.
> >
> > The line
> >
> >  if (dir_stat.st_mtime <= file_stat.st_mtime) {
> >
> > was removed recently from fccache.c, I think this was probably
> removed
> > by accident and was a mistake.
> 
> I doubt you really mean "recently".  Anyway, that was not a mistake.
> That
> line will cause lots of problems with clock skews and changes (which
> are not
> uncommon at new installations).  Instead, the cache stores the dir
> timestamp,
> and the two are compared for equality.

I am also afraid from comparing mtime's like above, so I do not think it is the correct fix.

> 
> I think the approach Diego proposes may be real the fix.  However, I'm
> puzzled
> as live font installation and uninstallation both work for me
> correctly.  I'll
> check it out again.
> 
> Diego, which fontconfig version are you using?

I am running 2.6.0.

I guess the reason why it works for you and not us is that we are only running one application that is using fontconfig and that we do not run fc-cache right after font install for a variety of reasons. In this case nobody is recreating the cache file and thus fontconfig finds that the copy it has already in memory is the same as the one on disk and in that case it does not bother to check for the cache being up to date. 

I am testing my proposed fix and will let you know how it goes shortly.

Diego

--
Diego Santa Cruz, PhD
Technology Architect
_________________________________
SpinetiX S.A.
Rue des Terreaux 17
1003, Lausanne, Switzerland
T +41 21 341 15 50
F +41 21 311 19 56
diego.santacruz@xxxxxxxxxxxx
http://www.spinetix.com
_________________________________


_______________________________________________
Fontconfig mailing list
Fontconfig@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/fontconfig

[Index of Archives]     [Fedora Fonts]     [Fedora Users]     [Fedora Cloud]     [Kernel]     [Fedora Packaging]     [Fedora Desktop]     [PAM]     [Gimp Graphics Editor]     [Yosemite News]

  Powered by Linux