Plug memory leak located by oddsock@oddsock.org.
authorMike Smith <msmith@xiph.org>
Sun, 2 Sep 2001 09:07:58 +0000 (09:07 +0000)
committerMike Smith <msmith@xiph.org>
Sun, 2 Sep 2001 09:07:58 +0000 (09:07 +0000)
Should p->noisethresh just be removed completely? It doesn't appear to be used
(currently, at least).

svn path=/trunk/vorbis/; revision=1948

lib/psy.c

index 233ccf3..726b3a9 100644 (file)
--- a/lib/psy.c
+++ b/lib/psy.c
@@ -11,7 +11,7 @@
  ********************************************************************
 
  function: psychoacoustics not including preecho
- last mod: $Id: psy.c,v 1.52 2001/09/01 06:14:50 xiphmont Exp $
+ last mod: $Id: psy.c,v 1.53 2001/09/02 09:07:58 msmith Exp $
 
  ********************************************************************/
 
@@ -429,8 +429,9 @@ void _vp_psy_clear(vorbis_look_psy *p){
        _ogg_free(p->tonecurves[i]);
       }
       _ogg_free(p->tonecurves);
-      _ogg_free(p->noiseoffset);
     }
+    _ogg_free(p->noiseoffset);
+    _ogg_free(p->noisethresh);
     memset(p,0,sizeof(vorbis_look_psy));
   }
 }