diff options
author | Paul Gilbert | 2012-05-04 23:20:01 +1000 |
---|---|---|
committer | Paul Gilbert | 2012-05-04 23:20:01 +1000 |
commit | e628da0cccbba04c9d19b28b46e97107ab66beb7 (patch) | |
tree | 42ae6c397acde303c88c303d2436e1d0835632e7 /engines/tony/mpal/memory.cpp | |
parent | 3184a5a874f3cfaa75424e7efb21f1cca3702988 (diff) | |
download | scummvm-rg350-e628da0cccbba04c9d19b28b46e97107ab66beb7.tar.gz scummvm-rg350-e628da0cccbba04c9d19b28b46e97107ab66beb7.tar.bz2 scummvm-rg350-e628da0cccbba04c9d19b28b46e97107ab66beb7.zip |
TONY: Fix some inconsistent allocation/deallocations
Diffstat (limited to 'engines/tony/mpal/memory.cpp')
-rw-r--r-- | engines/tony/mpal/memory.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/engines/tony/mpal/memory.cpp b/engines/tony/mpal/memory.cpp index 604e61ed24..de6e918a38 100644 --- a/engines/tony/mpal/memory.cpp +++ b/engines/tony/mpal/memory.cpp @@ -127,9 +127,9 @@ uint32 MemoryManager::getSize(HGLOBAL handle) { /** * Erases a given item */ -void MemoryManager::erase(MemoryItem &item) { +void MemoryManager::erase(MemoryItem *item) { delete item; - _memoryBlocks.remove(&item); + _memoryBlocks.remove(item); } /** @@ -137,7 +137,7 @@ void MemoryManager::erase(MemoryItem &item) { */ void MemoryManager::erase(HGLOBAL handle) { MemoryItem &item = getItem(handle); - erase(item); + erase(&item); } } // end of namespace MPAL |