From f27e6a27d6a234dfdb1482566369d12b3d62db91 Mon Sep 17 00:00:00 2001 From: Paweł Kołodziejski Date: Sun, 18 Jan 2004 09:35:05 +0000 Subject: cleanup svn-id: r12470 --- scumm/imuse_digi/dimuse_sndmgr.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'scumm') diff --git a/scumm/imuse_digi/dimuse_sndmgr.cpp b/scumm/imuse_digi/dimuse_sndmgr.cpp index e615278401..02417db551 100644 --- a/scumm/imuse_digi/dimuse_sndmgr.cpp +++ b/scumm/imuse_digi/dimuse_sndmgr.cpp @@ -38,8 +38,7 @@ ImuseDigiSndMgr::ImuseDigiSndMgr(ScummEngine *scumm) { ImuseDigiSndMgr::~ImuseDigiSndMgr() { for (int l = 0; l < MAX_IMUSE_SOUNDS; l++) { - if (&_sounds[l]) - closeSound(&_sounds[l]); + closeSound(&_sounds[l]); } #ifdef __PALM_OS__ BundleCodecs::releaseImcTables(); @@ -281,7 +280,8 @@ void ImuseDigiSndMgr::closeSound(soundStruct *soundHandle) { if (_sounds[l]._bundle) delete _sounds[l]._bundle; for (int r = 0; r < _sounds[l].numSyncs; r++) - free(_sounds[l].sync[r].ptr); + if (_sounds[l].sync[r].ptr) + free(_sounds[l].sync[r].ptr); memset(&_sounds[l], 0, sizeof(soundStruct)); } } -- cgit v1.2.3