TabDecorator.cpp: fix dereference of null pointer

Signed-off-by: Adrien Destugues <[email protected]>

fixes #13137
This commit is contained in:
Murai Takashi
2017-01-01 11:36:36 +01:00
committed by Adrien Destugues
parent 80d8697c0e
commit 22e3e14aab
+2 -1
View File
@@ -465,7 +465,8 @@ TabDecorator::_DistributeTabSize(float delta)
}
// done
previousTab->tabRect.right = floorf(fFrame.right + fBorderWidth);
if (previousTab != NULL)
previousTab->tabRect.right = floorf(fFrame.right + fBorderWidth);
for (int32 i = 0; i < tabCount; i++) {
Decorator::Tab* tab = fTabList.ItemAt(i);