ref: 63c501547cdeb85b66336d34c0f32995f5aad949
parent: 5c3061ebeab00ca6f9413f766462f270c1290740
author: Paul Brossier <piem@piem.org>
date: Mon Nov 26 11:59:56 EST 2018
[dct] fail fftw creation if size <= 0
--- a/src/spectral/dct_fftw.c
+++ b/src/spectral/dct_fftw.c
@@ -63,7 +63,9 @@
aubio_dct_fftw_t * new_aubio_dct_fftw (uint_t size) {
aubio_dct_fftw_t * s = AUBIO_NEW(aubio_dct_fftw_t);
- if (!s) {
+ if ((sint_t)size <= 0) {
+ AUBIO_ERR("dct_fftw: can only create with size > 0, requested %d\n",
+ size);
goto beach;
}
s->size = size;