changeset 593:821aba42c1bb

Fix some one-off memory leaks (including distracting ones in tests)
author Chris Cannam
date Mon, 06 Mar 2017 17:37:23 +0000
parents 1918bf5c9a9e
children 72b4870f0e6b
files audio/AudioGenerator.cpp
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/audio/AudioGenerator.cpp	Mon Mar 06 17:23:46 2017 +0000
+++ b/audio/AudioGenerator.cpp	Mon Mar 06 17:37:23 2017 +0000
@@ -67,6 +67,11 @@
 #ifdef DEBUG_AUDIO_GENERATOR
     SVDEBUG << "AudioGenerator::~AudioGenerator" << endl;
 #endif
+
+    for (int i = 0; i < m_channelBufCount; ++i) {
+        delete[] m_channelBuffer[i];
+    }
+    delete[] m_channelBuffer;
 }
 
 void