Handle invalid rects in kCanBeHere(). Fixes some odd crashes in Iceman

svn-id: r48098
This commit is contained in:
Filippos Karapetis 2010-02-21 00:50:27 +00:00
parent 24b0622e6f
commit 43ca6071ea

View File

@ -152,6 +152,9 @@ bool GfxCompare::kernelCanBeHere(reg_t curObject, reg_t listReference) {
checkRect.right = GET_SEL32V(_segMan, curObject, SELECTOR(brRight));
checkRect.bottom = GET_SEL32V(_segMan, curObject, SELECTOR(brBottom));
if (!checkRect.isValidRect()) // can occur in Iceman
return false;
adjustedRect = _coordAdjuster->onControl(checkRect);
signal = GET_SEL32V(_segMan, curObject, SELECTOR(signal));