From 624d05d7bce2c250016362f8af4cc27125ed67b8 Mon Sep 17 00:00:00 2001 From: Strangerke Date: Mon, 22 Jul 2013 09:25:08 +0200 Subject: MORTEVIELLE: Fix invalid read size in music code --- engines/mortevielle/mortevielle.h | 1 - engines/mortevielle/utils.cpp | 3 +-- 2 files changed, 1 insertion(+), 3 deletions(-) (limited to 'engines/mortevielle') diff --git a/engines/mortevielle/mortevielle.h b/engines/mortevielle/mortevielle.h index 28e342cb95..5c4389483c 100644 --- a/engines/mortevielle/mortevielle.h +++ b/engines/mortevielle/mortevielle.h @@ -69,7 +69,6 @@ const int kAdrPictureComp = 0x7000; const int kAdrCompMusicBuf1 = 0x7414; const int kAdrCompMusicBuf2 = 0x3800; -const int kAdrUnknownBuf = 0x47a0; const int kAdrDecBuffer = 0x73A2; #define ord(v) ((int) v) diff --git a/engines/mortevielle/utils.cpp b/engines/mortevielle/utils.cpp index 1a3b1f1ec1..a23c444b2e 100644 --- a/engines/mortevielle/utils.cpp +++ b/engines/mortevielle/utils.cpp @@ -2212,8 +2212,7 @@ void MortevielleEngine::music() { if (!fic.open("mort.img")) error("Missing file - mort.img"); - fic.read(&_mem[kAdrCompMusicBuf2 * 16], 500); - fic.read(&_mem[kAdrUnknownBuf * 16], 123); + fic.read(&_mem[kAdrCompMusicBuf2 * 16], 623 * 128); fic.close(); _soundManager.decodeMusic(&_mem[kAdrCompMusicBuf2 * 16], &_mem[kAdrMusic * 16], 623); -- cgit v1.2.3