diff options
author | Colin Snover | 2016-08-28 20:44:25 -0500 |
---|---|---|
committer | Colin Snover | 2016-09-29 19:39:16 -0500 |
commit | 78849053ca8abf203fe3f17972581416e86d334d (patch) | |
tree | 99806d21b2ed23a5ee5e787de5a6bb41bad8f72b /engines/sci | |
parent | 181676a0d515ab2ae4e7930bea7658e00f51d5d0 (diff) | |
download | scummvm-rg350-78849053ca8abf203fe3f17972581416e86d334d.tar.gz scummvm-rg350-78849053ca8abf203fe3f17972581416e86d334d.tar.bz2 scummvm-rg350-78849053ca8abf203fe3f17972581416e86d334d.zip |
SCI32: Fix off-by-one error
CID 1361599.
Diffstat (limited to 'engines/sci')
-rw-r--r-- | engines/sci/engine/klists.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/sci/engine/klists.cpp b/engines/sci/engine/klists.cpp index e780d3cdc3..db6ffb1310 100644 --- a/engines/sci/engine/klists.cpp +++ b/engines/sci/engine/klists.cpp @@ -554,7 +554,7 @@ reg_t kListEachElementDo(EngineState *s, int argc, reg_t *argv) { ++list->numRecursions; - if (list->numRecursions > ARRAYSIZE(list->nextNodes)) { + if (list->numRecursions >= ARRAYSIZE(list->nextNodes)) { error("Too much recursion in kListEachElementDo"); } |