diff options
author | Strangerke | 2013-02-25 23:22:07 +0100 |
---|---|---|
committer | Strangerke | 2013-02-25 23:22:07 +0100 |
commit | 9c6590fdeb546f2c55f57ca645d8bf7b5618ac9a (patch) | |
tree | de76b873f86f4540ca6581e7a8fbe2ee910c7f7c /engines/mortevielle | |
parent | 348e149739c6d97f282e352f6a97db6fff0be2dc (diff) | |
download | scummvm-rg350-9c6590fdeb546f2c55f57ca645d8bf7b5618ac9a.tar.gz scummvm-rg350-9c6590fdeb546f2c55f57ca645d8bf7b5618ac9a.tar.bz2 scummvm-rg350-9c6590fdeb546f2c55f57ca645d8bf7b5618ac9a.zip |
MORTEVIELLE: remove a magic value, initialize the last bytes of cfiecBuffer
Diffstat (limited to 'engines/mortevielle')
-rw-r--r-- | engines/mortevielle/mortevielle.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/engines/mortevielle/mortevielle.cpp b/engines/mortevielle/mortevielle.cpp index 3875d8d458..664908440f 100644 --- a/engines/mortevielle/mortevielle.cpp +++ b/engines/mortevielle/mortevielle.cpp @@ -597,7 +597,7 @@ void MortevielleEngine::mainGame() { loadCFIEC(); for (_crep = 1; _crep <= _x26KeyCount; ++_crep) - decodeNumber(&_cfiecBuffer[161 * 16], ((822 * 128) - (161 * 16)) / 64); + decodeNumber(&_cfiecBuffer[161 * 16], (_cfiecBufferSize - (161 * 16)) / 64); loadBRUIT5(); _menu.initMenu(); @@ -2498,6 +2498,9 @@ void MortevielleEngine::loadCFIEC() { for (int32 i = 0; i < fileSize; ++i) _cfiecBuffer[i] = f.readByte(); + for (int i = fileSize; i < _cfiecBufferSize; i++) + _cfiecBuffer[i] = 0; + f.close(); _reloadCFIEC = false; |