diff options
author | Eugene Sandulenko | 2016-05-31 13:32:04 +0200 |
---|---|---|
committer | Eugene Sandulenko | 2016-05-31 17:12:18 +0200 |
commit | 89890523c236681ebf32922d956587c9b44e270d (patch) | |
tree | 34b1e51a18add8e8c75289b25b982a91a4f4366c | |
parent | b53d8104b7b8db79fa91285838590bc0f41b5447 (diff) | |
download | scummvm-rg350-89890523c236681ebf32922d956587c9b44e270d.tar.gz scummvm-rg350-89890523c236681ebf32922d956587c9b44e270d.tar.bz2 scummvm-rg350-89890523c236681ebf32922d956587c9b44e270d.zip |
TINSEL: Guard against illegal memory writes
-rw-r--r-- | engines/tinsel/play.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/engines/tinsel/play.cpp b/engines/tinsel/play.cpp index ef3127233d..a4f5bc8261 100644 --- a/engines/tinsel/play.cpp +++ b/engines/tinsel/play.cpp @@ -159,6 +159,9 @@ static int RegisterSoundReel(SCNHANDLE hFilm, int column, int actorCol) { } } + if (i == MAX_SOUNDREELS) + error("Out of sound reels in RegisterSoundReel()"); + g_soundReelNumbers[i]++; return i; } |