summaryrefslogtreecommitdiff
path: root/fc-cache
diff options
context:
space:
mode:
authorAkira TAGOH <akira@tagoh.org>2014-12-16 20:43:02 +0900
committerAkira TAGOH <akira@tagoh.org>2014-12-16 20:43:02 +0900
commitdb64c71408636e2d0ac3c39682ac1b6c8f317ac4 (patch)
treef3734f75744b31532b2a3642ce616d9d27e73ba4 /fc-cache
parentaf5864419441e12f1951c7cfd0a742b6316934cc (diff)
fc-cache: make a fail if no fonts processed on a given path
Diffstat (limited to 'fc-cache')
-rw-r--r--fc-cache/fc-cache.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/fc-cache/fc-cache.c b/fc-cache/fc-cache.c
index 406ac6a8..e85c9fcb 100644
--- a/fc-cache/fc-cache.c
+++ b/fc-cache/fc-cache.c
@@ -126,7 +126,7 @@ scanDirs (FcStrList *list, FcConfig *config, FcBool force, FcBool really_force,
FcStrList *sublist;
FcCache *cache;
struct stat statb;
- FcBool was_valid;
+ FcBool was_valid, was_processed = FcFalse;
int i;
const FcChar8 *sysroot = FcConfigGetSysRoot (config);
@@ -175,6 +175,7 @@ scanDirs (FcStrList *list, FcConfig *config, FcBool force, FcBool really_force,
fprintf (stderr, "\"%s\": not a directory, skipping\n", dir);
continue;
}
+ was_processed = FcTrue;
if (really_force)
FcDirCacheUnlink (dir, config);
@@ -256,6 +257,8 @@ scanDirs (FcStrList *list, FcConfig *config, FcBool force, FcBool really_force,
else
FcDirCacheUnload (cache);
}
+ if (!was_processed)
+ ret++;
return ret;
}