projects
/
platform
/
upstream
/
fontconfig.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c80a08d
)
Free temporary string in FcDirCacheUnlink (Bug #11758)
author
Keith Packard
<keithp@neko.keithp.com>
Sun, 5 Aug 2007 19:31:03 +0000
(12:31 -0700)
committer
Keith Packard
<keithp@neko.keithp.com>
Sun, 5 Aug 2007 19:31:03 +0000
(12:31 -0700)
In FcDirCacheUnlink(), the line
cache_hashed = FcStrPlus (cache_dir, cache_base);
allocates memory in cache_hashed that is never free()'d before the function
exits.
Reported by Ben Combee.
src/fccache.c
patch
|
blob
|
history
diff --git
a/src/fccache.c
b/src/fccache.c
index
3185059
..
9e8819c
100644
(file)
--- a/
src/fccache.c
+++ b/
src/fccache.c
@@
-104,6
+104,7
@@
FcDirCacheUnlink (const FcChar8 *dir, FcConfig *config)
if (!cache_hashed)
break;
(void) unlink ((char *) cache_hashed);
+ FcStrFree (cache_hashed);
}
FcStrListDone (list);
/* return FcFalse if something went wrong */