shithub: aubio

Download patch

ref: 63bc67b6678213ee362e5e2159cfa07c470f8e83
parent: b1559f4c9ce2b304d8d27ffdc7128b6795ca82e5
author: Paul Brossier <piem@piem.org>
date: Sat Nov 24 13:03:01 EST 2018

[tests] check if tempo creation suceeded

--- a/tests/src/tempo/test-tempo.c
+++ b/tests/src/tempo/test-tempo.c
@@ -32,6 +32,8 @@
   // create tempo object
   aubio_tempo_t * o = new_aubio_tempo("default", win_size, hop_size, samplerate);
 
+  if (!o) { err = 1; goto beach_tempo; }
+
   do {
     // put some fresh data in input vector
     aubio_source_do(source, in, &read);
@@ -53,6 +55,7 @@
 
   // clean up memory
   del_aubio_tempo(o);
+beach_tempo:
   del_fvec(in);
   del_fvec(out);
   del_aubio_source(source);