Properly skip past dir caches that contain zero fonts (as occurs in global

caches.) Reported by Mike Fabian.
This commit is contained in:
Patrick Lam 2006-01-08 10:50:51 +00:00
parent 5fe09702f4
commit 05a98eaf4b
2 changed files with 10 additions and 0 deletions

View File

@ -1,3 +1,9 @@
2006-01-08 Patrick Lam <plam@mit.edu>
* src/fccache.c (FcDirCacheConsume):
Properly skip past dir caches that contain zero fonts (as occurs
in global caches.) Reported by Mike Fabian.
2006-01-06 Patrick Lam <plam@mit.edu>
* src/fcdbg.c (FcPatternPrint):

View File

@ -966,7 +966,11 @@ FcDirCacheConsume (int fd, const char * dir, FcFontSet *set)
return FcFalse;
if (!metadata.count)
{
pos = FcCacheNextOffset (lseek(fd, 0, SEEK_CUR));
lseek (fd, pos, SEEK_SET);
return FcTrue;
}
pos = FcCacheNextOffset (lseek(fd, 0, SEEK_CUR));
current_dir_block = mmap (0, metadata.count,