diff options
author | Paul Gilbert | 2012-06-10 17:56:52 +1000 |
---|---|---|
committer | Paul Gilbert | 2012-06-10 17:56:52 +1000 |
commit | e37319a28753f9b885e7c9d0a0e607d8090ae041 (patch) | |
tree | 0b2cd09e9f3a8959f453ee25a5a699a21e051afd /engines/tony | |
parent | 1668a231926d3ff8b464417bd8023d7a93839d21 (diff) | |
download | scummvm-rg350-e37319a28753f9b885e7c9d0a0e607d8090ae041.tar.gz scummvm-rg350-e37319a28753f9b885e7c9d0a0e607d8090ae041.tar.bz2 scummvm-rg350-e37319a28753f9b885e7c9d0a0e607d8090ae041.zip |
TONY: Fix data freeing in DialogStart
Diffstat (limited to 'engines/tony')
-rw-r--r-- | engines/tony/custom.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/engines/tony/custom.cpp b/engines/tony/custom.cpp index 6db6d5f858..e00db701f3 100644 --- a/engines/tony/custom.cpp +++ b/engines/tony/custom.cpp @@ -1985,7 +1985,7 @@ DECLARE_CUSTOM_FUNCTION(StartDialog)(CORO_PARAM, uint32 nDialog, uint32 nStartGr // If there is only one option, do it automatically, and wait for the next choice if (_ctx->num == 1) { mpalQueryDialogSelectionDWORD(_ctx->nChoice, _ctx->sl[0]); - globalFree(_ctx->sl); + globalDestroy(_ctx->sl); // Wait for the next choice to be made mpalQueryDialogWaitForChoice(&_ctx->nChoice); @@ -2001,7 +2001,7 @@ DECLARE_CUSTOM_FUNCTION(StartDialog)(CORO_PARAM, uint32 nDialog, uint32 nStartGr _ctx->string = mpalQueryDialogPeriod(_ctx->sl[_ctx->i]); assert(_ctx->string != NULL); _ctx->dc.addChoice(_ctx->string); - globalFree(_ctx->string); + globalDestroy(_ctx->string); } // Activate the object @@ -2028,7 +2028,7 @@ DECLARE_CUSTOM_FUNCTION(StartDialog)(CORO_PARAM, uint32 nDialog, uint32 nStartGr // Closes the choice _ctx->dc.close(); - globalFree(_ctx->sl); + globalDestroy(_ctx->sl); // Wait for the next choice to be made mpalQueryDialogWaitForChoice(&_ctx->nChoice); |