diff options
-rw-r--r-- | src/scalar.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/scalar.c b/src/scalar.c index 4ae3f16..0e3578f 100644 --- a/src/scalar.c +++ b/src/scalar.c @@ -992,6 +992,11 @@ int xtract_midicent(const double *data, const int N, const void *argv, double *r note *= 100; note = round(note); + if (note > 12700 || note < 0) + { + return XTRACT_ARGUMENT_ERROR; + } + return XTRACT_SUCCESS; } |