ref: cad7e919e0dd16239faab02aff7fd67837e98797
parent: 2f89ef46fee0b53e4ce65f81b7c5260eb7f62a18
author: Paul Brossier <piem@piem.org>
date: Mon Nov 28 13:48:03 EST 2016
src/io/source_sndfile.c: add missing floor in ratio comparison
--- a/src/io/source_sndfile.c
+++ b/src/io/source_sndfile.c
@@ -140,7 +140,7 @@
}
if (s->ratio > 1) {
// we would need to add a ring buffer for these
- if ( (uint_t)(s->input_hop_size * s->ratio + .5) != s->hop_size ) {
+ if ( (uint_t)FLOOR(s->input_hop_size * s->ratio + .5) != s->hop_size ) {
AUBIO_ERR("source_sndfile: can not upsample %s from %d to %d\n", s->path,
s->input_samplerate, s->samplerate);
goto beach;