summaryrefslogtreecommitdiff
path: root/src/sndobj/IFGram.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/sndobj/IFGram.cpp')
-rw-r--r--src/sndobj/IFGram.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/sndobj/IFGram.cpp b/src/sndobj/IFGram.cpp
index a5b374d..fb4cfa7 100644
--- a/src/sndobj/IFGram.cpp
+++ b/src/sndobj/IFGram.cpp
@@ -60,7 +60,14 @@ IFGram::IFGram(Table* window, SndObj* input, double scale,
}
IFGram::~IFGram(){
- delete[] m_diffwin;
+ if(m_diffwin){
+ delete[] m_diffwin;
+ m_diffwin = NULL;
+ }
+ if(m_pdiff){
+ delete[] m_pdiff;
+ m_pdiff = NULL;
+ }
fftw_destroy_plan(m_diffplan);
fftw_free(m_diffsig);