diff options
author | Travis Howell | 2006-03-13 11:52:16 +0000 |
---|---|---|
committer | Travis Howell | 2006-03-13 11:52:16 +0000 |
commit | b8cf88622b5a50d46702a9bdfd30ee2e4328c1f8 (patch) | |
tree | a4aeeb272015d7bf8afe11f2f6228b57d05a7b7c | |
parent | c5d90e026fcf46b7b566220acc1c5303073c020c (diff) | |
download | scummvm-rg350-b8cf88622b5a50d46702a9bdfd30ee2e4328c1f8.tar.gz scummvm-rg350-b8cf88622b5a50d46702a9bdfd30ee2e4328c1f8.tar.bz2 scummvm-rg350-b8cf88622b5a50d46702a9bdfd30ee2e4328c1f8.zip |
Fix a few valgrind warnings
svn-id: r21258
-rw-r--r-- | engines/lure/game.cpp | 2 | ||||
-rw-r--r-- | engines/lure/menu.cpp | 2 | ||||
-rw-r--r-- | engines/lure/res.cpp | 2 | ||||
-rw-r--r-- | engines/lure/room.cpp | 1 |
4 files changed, 4 insertions, 3 deletions
diff --git a/engines/lure/game.cpp b/engines/lure/game.cpp index 7c8fc98c1d..a58dba2d19 100644 --- a/engines/lure/game.cpp +++ b/engines/lure/game.cpp @@ -69,7 +69,7 @@ void Game::nextFrame() { hotspot->tick(); } - delete idList; + delete[] idList; Screen::getReference().update(); } diff --git a/engines/lure/menu.cpp b/engines/lure/menu.cpp index 8051e14fac..2f881934cc 100644 --- a/engines/lure/menu.cpp +++ b/engines/lure/menu.cpp @@ -58,7 +58,7 @@ MenuRecord::MenuRecord(uint16 hsxstartVal, uint16 hsxendVal, uint16 xstartVal, } MenuRecord::~MenuRecord() { - delete _entries[0]; // Delete string data for all the menu items + free(_entries[0]); // Delete string data for all the menu items free(_entries); // Free the list } diff --git a/engines/lure/res.cpp b/engines/lure/res.cpp index 2b4e7fd180..cca901a334 100644 --- a/engines/lure/res.cpp +++ b/engines/lure/res.cpp @@ -55,7 +55,7 @@ void Resources::freeData() { delete _paletteSubset; delete _scriptData; delete _script2Data; - delete _hotspotScriptData; + free(_hotspotScriptData); delete _messagesData; delete _cursors; } diff --git a/engines/lure/room.cpp b/engines/lure/room.cpp index e27f9cfbdb..6346181cc0 100644 --- a/engines/lure/room.cpp +++ b/engines/lure/room.cpp @@ -76,6 +76,7 @@ Room::Room(): _screen(Screen::getReference()) { _roomData = NULL; _talkDialog = NULL; + _hotspotId = 0; _hotspotName[0] = '\0'; for (int ctr = 0; ctr < MAX_NUM_LAYERS; ++ctr) _layers[ctr] = NULL; _numLayers = 0; |