* Fix memory leak in ftmac.c, patch by Jjgod Jiang

This commit is contained in:
Suzuki, Toshiya (鈴木俊哉) 2007-02-20 02:37:36 +00:00
parent a091517a04
commit b68e025c1b
3 changed files with 8 additions and 0 deletions

View File

@ -1,3 +1,9 @@
2007-02-20 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
* src/base/ftmac.c (FT_GetFileRef_From_Mac_ATS_Name): Fix memory
leak, patch by "Jjgod Jiang" <gzjjgod@gmail.com>.
* builds/mac/ftmac.c (FT_GetFileRef_From_Mac_ATS_Name): Ditto.
2007-02-16 Werner Lemberg <wl@gnu.org>
* src/truetype/ttinterp.c (Ins_MD): Remove unused variable.

View File

@ -283,6 +283,7 @@
kCFStringEncodingMacRoman );
ats_font_id = ATSFontFindFromName( cf_fontName,
kATSOptionFlagsUnRestrictedScope );
CFRelease(cf_fontName);
if ( ats_font_id == 0 || ats_font_id == 0xFFFFFFFFUL )
return FT_Err_Unknown_File_Format;

View File

@ -145,6 +145,7 @@
kCFStringEncodingMacRoman );
ats_font_id = ATSFontFindFromName( cf_fontName,
kATSOptionFlagsUnRestrictedScope );
CFRelease( cf_fontName );
if ( ats_font_id == 0 || ats_font_id == 0xFFFFFFFFUL )
return FT_Err_Unknown_File_Format;