diff options
author | Eugene Sandulenko | 2016-08-25 09:54:25 +0200 |
---|---|---|
committer | Eugene Sandulenko | 2016-08-25 10:22:20 +0200 |
commit | a5b97a989cc117799706a0c82bc686f79d6eda9f (patch) | |
tree | 85339c8bcc1cd5c105bc75e968d7347c632c2cea /engines | |
parent | 03cf47008258629645087a9df68066f990b674a6 (diff) | |
download | scummvm-rg350-a5b97a989cc117799706a0c82bc686f79d6eda9f.tar.gz scummvm-rg350-a5b97a989cc117799706a0c82bc686f79d6eda9f.tar.bz2 scummvm-rg350-a5b97a989cc117799706a0c82bc686f79d6eda9f.zip |
DIRECTOR: Fix numerous crashes on destruction
Diffstat (limited to 'engines')
-rw-r--r-- | engines/director/director.cpp | 4 | ||||
-rw-r--r-- | engines/director/score.cpp | 3 |
2 files changed, 2 insertions, 5 deletions
diff --git a/engines/director/director.cpp b/engines/director/director.cpp index 4e2973b163..89bac290b8 100644 --- a/engines/director/director.cpp +++ b/engines/director/director.cpp @@ -73,14 +73,12 @@ DirectorEngine::~DirectorEngine() { delete _sharedBMP; delete _sharedSTXT; delete _sharedDIB; - delete _movies; + delete _currentScore; delete _mainArchive; delete _macBinary; delete _soundManager; delete _lingo; - delete _currentScore; - delete _currentPalette; } Common::Error DirectorEngine::run() { diff --git a/engines/director/score.cpp b/engines/director/score.cpp index 2448ab08a8..c4294fdb77 100644 --- a/engines/director/score.cpp +++ b/engines/director/score.cpp @@ -97,6 +97,7 @@ Score::Score(DirectorEngine *vm) { _lingo->processEvent(kEventPrepareMovie, 0); _movieScriptCount = 0; _labels = NULL; + _font = NULL; if (_movieArchive->hasResource(MKTAG('M','C','N','M'), 0)) { _macName = _movieArchive->getName(MKTAG('M','C','N','M'), 0).c_str(); @@ -181,8 +182,6 @@ Score::~Score() { _movieArchive->close(); delete _font; - delete _movieArchive; - delete _labels; } |