aboutsummaryrefslogtreecommitdiff
path: root/fft
diff options
context:
space:
mode:
Diffstat (limited to 'fft')
-rw-r--r--fft/fft.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fft/fft.c b/fft/fft.c
index 69c0971..7cb5374 100644
--- a/fft/fft.c
+++ b/fft/fft.c
@@ -4,7 +4,7 @@
void fft_write(struct fmplayer_fft_data *data, const int16_t *buf, unsigned len) {
if (len > FFTLEN) {
- unsigned discard = FFTLEN - len;
+ unsigned discard = len - FFTLEN;
buf += discard*2;
len = FFTLEN;
}