From 9090cb9eceec10581c9f927b2e895189d20d1d4c Mon Sep 17 00:00:00 2001 From: Patrick Lam Date: Wed, 2 Nov 2005 06:39:23 +0000 Subject: [PATCH] Fix thinko: actually, the whole global cache is stale if the global cache is older than the (newest) config file. --- ChangeLog | 6 ++++++ src/fccache.c | 6 +++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 446d53f..fdd56ee 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2005-11-02 Patrick Lam + * src/fccache.c (FcGlobalCacheLoad): + + Fix thinko: actually, the whole global cache is stale + if the global cache is older than the (newest) config file. + 2005-11-02 Patrick Lam * src/fccache.c (FcGlobalCacheLoad): * src/fccfg.c (FcConfigModifiedTime, FcConfigBuildFonts): diff --git a/src/fccache.c b/src/fccache.c index 970a614..69bb385 100644 --- a/src/fccache.c +++ b/src/fccache.c @@ -193,11 +193,11 @@ FcGlobalCacheLoad (FcGlobalCache *cache, if (!strlen(name_buf)) break; - /* Directory must be older than the global cache file, and - also must be older than the config file. */ + /* Directory must be older than the global cache file; also + cache must be newer than the config file. */ if (stat ((char *) name_buf, &dir_stat) < 0 || dir_stat.st_mtime > cache_stat.st_mtime || - (config_time.set && dir_stat.st_mtime > config_time.time)) + (config_time.set && cache_stat.st_mtime < config_time.time)) { FcCache md;