]> git.wh0rd.org - fontconfig.git/blobdiff - src/fccache.c
Make cache reference counting more efficient.
[fontconfig.git] / src / fccache.c
index 69a29f2e94658c627c2417cc63d108352275e30e..77a303d77a044e59bedb6a3ba70e0e030115aca5 100644 (file)
@@ -476,6 +476,15 @@ FcDirCacheMapFd (int fd, struct stat *fd_stat)
     return cache;
 }
 
+void
+FcDirCacheReference (FcCache *cache, int nref)
+{
+    FcCacheSkip *skip = FcCacheFindByAddr (cache);
+
+    if (skip)
+       skip->ref += nref;
+}
+
 void
 FcDirCacheUnload (FcCache *cache)
 {