From 370107c95326a8fafd816aed741e7842355c573e Mon Sep 17 00:00:00 2001 From: Sven Hesse Date: Mon, 3 Aug 2015 15:56:43 +0200 Subject: GOB: Remove a useless call to Variables::getAddressOff8() This is a left-over vestige of when the gob engine recorded the size of each variable currently in use, because it byte-swapped all variables on save/load depending on the machine ScummVM ran on. The gob engine doesn't do that all anymore (instead, the variables are always stored in the endianness of the original game), so getAddressOff8() doesn't store "this is an 8-bit variable" anymore, making the call a NOP. This fixes Coverity Scan issue #1267142. --- engines/gob/map_v2.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'engines/gob') diff --git a/engines/gob/map_v2.cpp b/engines/gob/map_v2.cpp index cb5abe9644..370e62c88f 100644 --- a/engines/gob/map_v2.cpp +++ b/engines/gob/map_v2.cpp @@ -163,11 +163,9 @@ void Map_v2::loadMapObjects(const char *avjFile) { mapHeight = _screenHeight / _tilesHeight; mapWidth = _screenWidth / _tilesWidth; - for (int i = 0; i < mapHeight; i++) { + for (int i = 0; i < mapHeight; i++) for (int j = 0; j < mapWidth; j++) setPass(j, i, mapData.readSByte()); - _vm->_inter->_variables->getAddressOff8(var + i * _passWidth); - } } mapData.seek(tmpPos); -- cgit v1.2.3