diff --git a/cocos/2d/CCFontFreeType.cpp b/cocos/2d/CCFontFreeType.cpp index 56dca6b18f..967262ef70 100644 --- a/cocos/2d/CCFontFreeType.cpp +++ b/cocos/2d/CCFontFreeType.cpp @@ -63,6 +63,7 @@ FontFreeType * FontFreeType::create(const std::string &fontName, float fontSize, delete tempFont; return nullptr; } + tempFont->autorelease(); return tempFont; }