aboutsummaryrefslogtreecommitdiff
path: root/engines/director/lingo/lingo-builtins.cpp
diff options
context:
space:
mode:
authorEugene Sandulenko2019-12-10 00:53:14 +0100
committerEugene Sandulenko2019-12-10 00:53:14 +0100
commit5673fc90b36044dca2642e904e73259e4b2d4b99 (patch)
tree249df85fe9e9d75aa456e5526613e947fa625e41 /engines/director/lingo/lingo-builtins.cpp
parent303b418dda38c4d4b88411c0a73ce387911b8ccb (diff)
downloadscummvm-rg350-5673fc90b36044dca2642e904e73259e4b2d4b99.tar.gz
scummvm-rg350-5673fc90b36044dca2642e904e73259e4b2d4b99.tar.bz2
scummvm-rg350-5673fc90b36044dca2642e904e73259e4b2d4b99.zip
DIRECTOR: LINGO: Fix bounds check in b_zoomBox
Diffstat (limited to 'engines/director/lingo/lingo-builtins.cpp')
-rw-r--r--engines/director/lingo/lingo-builtins.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/director/lingo/lingo-builtins.cpp b/engines/director/lingo/lingo-builtins.cpp
index a8e8c75e6a..c5d7cbf4cd 100644
--- a/engines/director/lingo/lingo-builtins.cpp
+++ b/engines/director/lingo/lingo-builtins.cpp
@@ -1316,7 +1316,7 @@ void Lingo::b_zoomBox(int nargs) {
// Looks for endSprite in the next frame
Common::Rect *endRect = frame->getSpriteRect(endSprite.u.i);
if (!endRect) {
- if (score->_frames.size() > curFrame)
+ if (score->_frames.size() - 1 > curFrame)
score->_frames[curFrame + 1]->getSpriteRect(endSprite.u.i);
}