diff data/fileio/test/AudioFileReaderTest.h @ 1402:aadfb395e933

Fix some one-off memory leaks (including distracting ones in tests)
author Chris Cannam
date Mon, 06 Mar 2017 17:37:23 +0000
parents 1c9bbbb6116a
children 87ae75da6527
line wrap: on
line diff
--- a/data/fileio/test/AudioFileReaderTest.h	Mon Mar 06 17:23:46 2017 +0000
+++ b/data/fileio/test/AudioFileReaderTest.h	Mon Mar 06 17:37:23 2017 +0000
@@ -287,6 +287,10 @@
 	// expected number back (if this is not mp3/aac) or (b) take
 	// into account silence at beginning and end (if it is).
 	floatvec_t test = reader->getInterleavedFrames(0, refFrames + 5000);
+
+        delete reader;
+        reader = 0;
+        
 	sv_frame_t read = test.size() / channels;
 
         bool perceptual = (extension == "mp3" ||