From c5caf558a7d940b59fb66eca33c813d6ddd559bb Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Wed, 4 Apr 2007 10:24:29 +0200 Subject: [PATCH 1/1] compress.c: fix serious typo We always compute the peak using the _adjusted_ sample value. --- compress.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compress.c b/compress.c index 685c3ba9..63c9b002 100644 --- a/compress.c +++ b/compress.c @@ -73,7 +73,7 @@ static ssize_t compress(char *inbuf, size_t inbuf_len, struct filter_node *fn) pcd->peak = 0; } else if (adjusted_sample > pcd->peak) - pcd->peak = sample; + pcd->peak = adjusted_sample; } else { adjusted_sample = -((-sample * pcd->current_gain) >> gain_shift); -- 2.39.2