From 88c4748a4b93b6dcf0a8288c030bf93ae571ce5e Mon Sep 17 00:00:00 2001 From: Michael Sevakis Date: Fri, 16 Nov 2007 14:49:17 +0000 Subject: [PATCH] Couple more tiny changes. :) git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15639 a1c6a512-1295-4272-9138-f99709370657 --- apps/pcmbuf.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/apps/pcmbuf.c b/apps/pcmbuf.c index b887264997..49333d108b 100644 --- a/apps/pcmbuf.c +++ b/apps/pcmbuf.c @@ -680,7 +680,7 @@ static size_t crossfade_fade_mix(int factor, const char *buf, size_t fade_rem) while (fade_rem) { - int sample = *input_buf++; + int32_t sample = *input_buf++; sample = ((sample * factor) >> 8) + *output_buf; *output_buf++ = clip_sample_16(sample); fade_rem -= 2; @@ -1050,8 +1050,9 @@ void pcmbuf_mix_voice(int count) count <<= 1; - while (count-- > 0) { - int sample = *ibuf++; + while (count-- > 0) + { + int32_t sample = *ibuf++; if (pcmbuf_mix_sample >= chunk_samples) { pcmbuf_mix_chunk = pcmbuf_mix_chunk->link;