summaryrefslogtreecommitdiff
path: root/fc-cache
diff options
context:
space:
mode:
authorPatrick Lam <plam@MIT.EDU>2006-01-31 04:07:45 +0000
committerPatrick Lam <plam@MIT.EDU>2006-01-31 04:07:45 +0000
commit275cf6cd8350f8a9f29caabd5b1994c6324caaf6 (patch)
tree98891422b0c57125cfba2caf0651277870968e25 /fc-cache
parent81d97094cf2a714417a9e73bb2f0f17f51ca3d95 (diff)
Don't stop scanning if a directory in fonts.conf doesn't exist, because
subsequent directories might exist. reviewed by: plam
Diffstat (limited to 'fc-cache')
-rw-r--r--fc-cache/fc-cache.c20
1 files changed, 14 insertions, 6 deletions
diff --git a/fc-cache/fc-cache.c b/fc-cache/fc-cache.c
index 2d6c2c3..f93a085 100644
--- a/fc-cache/fc-cache.c
+++ b/fc-cache/fc-cache.c
@@ -113,6 +113,7 @@ scanDirs (FcStrList *list, FcConfig *config, char *program, FcBool force, FcBool
{
int ret = 0;
const FcChar8 *dir;
+ const FcChar8 *dir_orig;
FcFontSet *set;
FcStrSet *subdirs;
FcStrList *sublist;
@@ -122,17 +123,24 @@ scanDirs (FcStrList *list, FcConfig *config, char *program, FcBool force, FcBool
* Now scan all of the directories into separate databases
* and write out the results
*/
- while ((dir = FcStrListNext (list)))
+ while ((dir_orig = FcStrListNext (list)))
{
- dir = FcConfigNormalizeFontDir (config, dir);
- if (!dir)
- return FcFalse;
-
+ dir = FcConfigNormalizeFontDir (config, dir_orig);
+
if (verbose)
{
- printf ("%s: \"%s\": ", program, dir);
+ printf ("%s: \"%s\": ", program, dir ? dir : dir_orig);
fflush (stdout);
}
+
+ if (!dir)
+ {
+ if (verbose)
+ printf ("skipping, no such directory\n");
+ continue;
+ }
+
+
set = FcFontSetCreate ();
if (!set)
{