diff dsp/signalconditioning/FiltFilt.cpp @ 283:5e125f030287

* Fixes to problems shown up by vamp-plugin-tester. Still not all plugins pass all tests, though
author Chris Cannam <c.cannam@qmul.ac.uk>
date Mon, 23 Mar 2009 16:28:53 +0000
parents 49844bc8a895
children e5907ae6de17
line wrap: on
line diff
--- a/dsp/signalconditioning/FiltFilt.cpp	Fri Feb 27 13:07:22 2009 +0000
+++ b/dsp/signalconditioning/FiltFilt.cpp	Mon Mar 23 16:28:53 2009 +0000
@@ -48,11 +48,12 @@
 {	
     unsigned int i;
 
+    if (length == 0) return;
+
     unsigned int nFilt = m_ord + 1;
     unsigned int nFact = 3 * ( nFilt - 1);
     unsigned int nExt	= length + 2 * nFact;
 
-
     m_filtScratchIn = new double[ nExt ];
     m_filtScratchOut = new double[ nExt ];