From 4b1276e24058a2e8b283767fb11dd2d16de7e547 Mon Sep 17 00:00:00 2001 From: Akira TAGOH Date: Thu, 19 Jul 2018 11:40:31 +0900 Subject: [PATCH] Fix memory leak --- src/fccache.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/fccache.c b/src/fccache.c index 6919e7a..6734865 100644 --- a/src/fccache.c +++ b/src/fccache.c @@ -1348,9 +1348,9 @@ FcDirCacheWrite (FcCache *cache, FcConfig *config) #endif FcDirCacheBasenameMD5 (dir, cache_base); cache_hashed = FcStrBuildFilename (cache_dir, cache_base, NULL); + FcStrFree (cache_dir); if (!cache_hashed) return FcFalse; - FcStrFree (cache_dir); if (FcDebug () & FC_DBG_CACHE) printf ("FcDirCacheWriteDir dir \"%s\" file \"%s\"\n",