Fixed null profile crash

If the profile was null it would crash.
This commit is contained in:
Nathan Bowhay 2015-01-29 15:58:41 -08:00
parent fe544597e3
commit 789cc47b67

View file

@ -622,7 +622,7 @@ S32 GuiTabBookCtrl::calculatePageTabWidth( GuiTabPageCtrl *page )
const char* text = page->getText();
if( !text || dStrlen(text) == 0 || mProfile->mFont == NULL )
if( !text || dStrlen(text) == 0 || mProfile == NULL || mProfile->mFont == NULL )
return mMinTabWidth;
GFont *font = mProfile->mFont;