aboutsummaryrefslogtreecommitdiff
path: root/engines/bladerunner
diff options
context:
space:
mode:
authorThomas Fach-Pedersen2016-10-24 19:28:47 +0200
committerThomas Fach-Pedersen2016-10-24 19:40:18 +0200
commit8045edab27488ba3cc849be613afe893cb4317e5 (patch)
tree1e8ecd0594f7d61ba5e7895b2f36251a8cdb64d1 /engines/bladerunner
parente0a04a3185d92b0979babdf23a3eaf49c5d815a8 (diff)
downloadscummvm-rg350-8045edab27488ba3cc849be613afe893cb4317e5.tar.gz
scummvm-rg350-8045edab27488ba3cc849be613afe893cb4317e5.tar.bz2
scummvm-rg350-8045edab27488ba3cc849be613afe893cb4317e5.zip
BLADERUNNER: Fix out-of-bounds write (CID 1364262)
Diffstat (limited to 'engines/bladerunner')
-rw-r--r--engines/bladerunner/movement_track.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/bladerunner/movement_track.cpp b/engines/bladerunner/movement_track.cpp
index 60a190a9a2..bd74116566 100644
--- a/engines/bladerunner/movement_track.cpp
+++ b/engines/bladerunner/movement_track.cpp
@@ -50,7 +50,7 @@ int MovementTrack::append(int waypointId, int delay, int running) {
}
int MovementTrack::append(int waypointId, int delay, int angle, int running) {
- if (_lastIndex > ARRAYSIZE(_entries))
+ if (_lastIndex >= ARRAYSIZE(_entries))
return 0;
_entries[_lastIndex].waypointId = waypointId;