Added a MEM_freeN call to sound_free_sound() to release bSound->stream
authorAlexander Ewering <blender@instinctive.de>
Fri, 18 Jul 2003 15:30:12 +0000 (15:30 +0000)
committerAlexander Ewering <blender@instinctive.de>
Fri, 18 Jul 2003 15:30:12 +0000 (15:30 +0000)
created by audio_makestream(). Fixes "Err Totblck stream len..." messages
and memory leak.

source/blender/blenkernel/intern/sound.c

index 9d33e9163ce1e80121633d42abfe738779189f18..e4449ad0139af400d79b48586a9750fdbc103f73 100644 (file)
@@ -33,7 +33,7 @@ void sound_free_sound(bSound *sound)
        //if (sound) {
        //      sound_set_sample(sound, NULL);
        //}
-       
+       if (sound->stream) MEM_freeN(sound->stream);
 }
 
 void sound_free_sample(bSample *sample)