Fix a shutdown crash with close fonts.

This commit is contained in:
Unknown W. Brackets 2013-03-09 00:54:16 -08:00
parent f3a10fb4c3
commit ab66aa4c45

View File

@ -190,7 +190,7 @@ public:
: fontLibID_(fontLibID), font_(font), handle_(handle) {}
Font *GetFont() { return font_; }
FontLib *GetFontLib() { return fontLibList[fontLibID_]; }
FontLib *GetFontLib() { if (!IsOpen()) return NULL; return fontLibList[fontLibID_]; }
u32 Handle() const { return handle_; }
bool IsOpen() const { return fontLibID_ != (u32)-1; }