aboutsummaryrefslogtreecommitdiff
path: root/engines/fullpipe/lift.cpp
diff options
context:
space:
mode:
authorColin Snover2017-11-16 23:47:57 -0600
committerEugene Sandulenko2017-11-18 22:35:12 +0100
commitc9327f29859dcbbeca99a116d9ce2aebf366ced1 (patch)
tree823c5400e292ba1f4b72b73a7426245495d9f84a /engines/fullpipe/lift.cpp
parent7323bef77bd6acf180a6316950c06723075e8299 (diff)
downloadscummvm-rg350-c9327f29859dcbbeca99a116d9ce2aebf366ced1.tar.gz
scummvm-rg350-c9327f29859dcbbeca99a116d9ce2aebf366ced1.tar.bz2
scummvm-rg350-c9327f29859dcbbeca99a116d9ce2aebf366ced1.zip
FULLPIPE: Fix memory leaks of PreloadItems
Diffstat (limited to 'engines/fullpipe/lift.cpp')
-rw-r--r--engines/fullpipe/lift.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/engines/fullpipe/lift.cpp b/engines/fullpipe/lift.cpp
index 1bbe5a726b..feee335555 100644
--- a/engines/fullpipe/lift.cpp
+++ b/engines/fullpipe/lift.cpp
@@ -403,12 +403,12 @@ void FullpipeEngine::lift_goAnimation() {
int numItems = _gameLoader->_preloadItems.size();
for (int i = 0; i < numItems; i++) {
- PreloadItem *pre = _gameLoader->_preloadItems[i];
+ PreloadItem &pre = _gameLoader->_preloadItems[i];
- if (pre->preloadId2 == buttonId && pre->preloadId1 == _currentScene->_sceneId) {
+ if (pre.preloadId2 == buttonId && pre.preloadId1 == _currentScene->_sceneId) {
MessageQueue *mq = new MessageQueue(_globalMessageQueueList->compact());
- ExCommand *ex = new ExCommand(ANI_MAN, 1, (pre->param != LiftDown ? MV_MAN_LIFTDOWN : MV_MAN_LIFTUP), 0, 0, 0, 1, 0, 0, 0);
+ ExCommand *ex = new ExCommand(ANI_MAN, 1, (pre.param != LiftDown ? MV_MAN_LIFTDOWN : MV_MAN_LIFTUP), 0, 0, 0, 1, 0, 0, 0);
ex->_param = -1;
ex->_field_24 = 1;