bug 711357 - release the CGFontRef after creating our font entry (which holds its own reference). r=jdaggett

This commit is contained in:
Jonathan Kew 2011-12-19 10:36:05 +00:00
parent 0236199d36
commit ebaa9ad3ce

View File

@ -1004,6 +1004,7 @@ gfxMacPlatformFontList::MakePlatformFontCG(const gfxProxyFontEntry *aProxyEntry,
aProxyEntry->mItalic ? aProxyEntry->mItalic ?
FONT_STYLE_ITALIC : FONT_STYLE_NORMAL, FONT_STYLE_ITALIC : FONT_STYLE_NORMAL,
true, false)); true, false));
::CFRelease(fontRef);
// if succeeded and font cmap is good, return the new font // if succeeded and font cmap is good, return the new font
if (newFontEntry->mIsValid && NS_SUCCEEDED(newFontEntry->ReadCMAP())) { if (newFontEntry->mIsValid && NS_SUCCEEDED(newFontEntry->ReadCMAP())) {