From 428f8d6955202a238ea7a8e887d707503a487449 Mon Sep 17 00:00:00 2001 From: Torbjörn Andersson Date: Tue, 19 Jan 2010 20:41:51 +0000 Subject: Fixed some cppcheck warnings. svn-id: r47393 --- sound/mods/tfmx.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sound/mods/tfmx.cpp') diff --git a/sound/mods/tfmx.cpp b/sound/mods/tfmx.cpp index 2ef7d79b7a..50cc68eb6b 100644 --- a/sound/mods/tfmx.cpp +++ b/sound/mods/tfmx.cpp @@ -887,7 +887,7 @@ const int8 *Tfmx::loadSampleFile(uint32 &sampleLen, Common::SeekableReadStream & sampleAlloc[0] = sampleAlloc[1] = sampleAlloc[2] = sampleAlloc[3] = 0; sampleLen = sampleSize; } else { - delete sampleAlloc; + delete[] sampleAlloc; warning("Tfmx: Encountered IO-Error"); return 0; } @@ -994,7 +994,7 @@ const Tfmx::MdatResource *Tfmx::loadMdatFile(Common::SeekableReadStream &musicDa resource->mdatData = mdatAlloc - mdatOffset; resource->mdatLen = mdatSize; } else { - delete mdatAlloc; + delete[] mdatAlloc; warning("Tfmx: Encountered IO-Error"); delete resource; return 0; -- cgit v1.2.3