From a2cb8ddcdd4ddf64bac2470d5a7aa15b7ce81849 Mon Sep 17 00:00:00 2001 From: Strangerke Date: Tue, 12 Jan 2016 11:14:44 +0100 Subject: VOYEUR: Add a safeguard in getVOCFileName --- engines/voyeur/sound.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'engines') diff --git a/engines/voyeur/sound.cpp b/engines/voyeur/sound.cpp index c0e5a043cd..0e9d35e9a6 100644 --- a/engines/voyeur/sound.cpp +++ b/engines/voyeur/sound.cpp @@ -54,6 +54,7 @@ void SoundManager::setVOCOffset(int offset) { } Common::String SoundManager::getVOCFileName(int idx) { + assert (idx >= 0); return Common::String::format("%s.voc", SZ_FILENAMES[idx]); } -- cgit v1.2.3