ref: 2296ffbfd85b62393bb1af8a5a52fa5488e98dc0
parent: cf5c2cab070f74b64b043a179fb4dbd7e5fe7e20
author: Paul Brossier <piem@piem.org>
date: Sun Feb 26 18:38:35 EST 2017
src/io/source_wavread.c: set error message in seek if pos < 0
--- a/src/io/source_wavread.c
+++ b/src/io/source_wavread.c
@@ -408,6 +408,7 @@
uint_t aubio_source_wavread_seek (aubio_source_wavread_t * s, uint_t pos) {
uint_t ret = 0;
if ((sint_t)pos < 0) {
+ AUBIO_ERR("source_wavread: could not seek %s at %d (seeking position should be >= 0)\n", s->path, pos);
return AUBIO_FAIL;
}
ret = fseek(s->fid, s->seek_start + pos * s->blockalign, SEEK_SET);