aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
Diffstat (limited to 'engines')
-rw-r--r--engines/sci/graphics/compare.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/engines/sci/graphics/compare.cpp b/engines/sci/graphics/compare.cpp
index 689c871e64..cf57d98b52 100644
--- a/engines/sci/graphics/compare.cpp
+++ b/engines/sci/graphics/compare.cpp
@@ -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));