diff options
author | David Turner | 2011-01-13 17:26:00 +0000 |
---|---|---|
committer | David Turner | 2011-01-13 17:26:00 +0000 |
commit | 9118d2915cf12f5bfac36895e4628358882fcfa0 (patch) | |
tree | d911315280f17b51ec46b362ca51ffa2d738ff32 /engines | |
parent | da6fdff421d8f8ccb37d3c31c12dec12fab4cea4 (diff) | |
download | scummvm-rg350-9118d2915cf12f5bfac36895e4628358882fcfa0.tar.gz scummvm-rg350-9118d2915cf12f5bfac36895e4628358882fcfa0.tar.bz2 scummvm-rg350-9118d2915cf12f5bfac36895e4628358882fcfa0.zip |
PARALLACTION: Close Memory Leak in Big Red Adventure Subtitles.
svn-id: r55229
Diffstat (limited to 'engines')
-rw-r--r-- | engines/parallaction/exec_br.cpp | 4 | ||||
-rw-r--r-- | engines/parallaction/parallaction_br.cpp | 1 |
2 files changed, 4 insertions, 1 deletions
diff --git a/engines/parallaction/exec_br.cpp b/engines/parallaction/exec_br.cpp index 1d8724e2d8..99aa27b30f 100644 --- a/engines/parallaction/exec_br.cpp +++ b/engines/parallaction/exec_br.cpp @@ -107,10 +107,14 @@ void Parallaction_br::clearSubtitles() { if (_subtitle[0]) { _gfx->hideLabel(_subtitle[0]); } + delete _subtitle[0]; + _subtitle[0] = 0; if (_subtitle[1]) { _gfx->hideLabel(_subtitle[1]); } + delete _subtitle[1]; + _subtitle[1] = 0; } diff --git a/engines/parallaction/parallaction_br.cpp b/engines/parallaction/parallaction_br.cpp index c39989de45..457c421fd7 100644 --- a/engines/parallaction/parallaction_br.cpp +++ b/engines/parallaction/parallaction_br.cpp @@ -228,7 +228,6 @@ void Parallaction_br::freeCharacter() { void Parallaction_br::freeLocation(bool removeAll) { // free open location stuff clearSubtitles(); - _subtitle[0] = _subtitle[1] = 0; _localFlagNames->clear(); |