Don't leak header in non-error case (Coverity defect #1825).

reviewed by: plam
This commit is contained in:
Patrick Lam 2006-04-10 16:12:55 +00:00
parent 65448e8b2a
commit c814c301ee
2 changed files with 8 additions and 0 deletions

View File

@ -1,3 +1,9 @@
2006-04-10 Frederic Crozat <fcrozat@mandriva.com>
reviewed by: plam
* src/fccache.c: (FcGlobalCacheSave):
Don't leak header in non-error case (Coverity defect #1825).
2006-04-10 Frederic Crozat <fcrozat@mandriva.com>
reviewed by: plam

View File

@ -501,6 +501,8 @@ FcGlobalCacheSave (FcGlobalCache *cache,
if (!FcCacheWriteString (fd, header))
goto bail4;
free (header);
for (dir = cache->dirs; dir; dir = dir->next)
{
int i;