From: Jaroslav Kysela Date: Sat, 23 Feb 2002 09:28:47 +0000 (+0000) Subject: Fixed count overflow problem X-Git-Tag: v1.0.3~149 X-Git-Url: https://git.alsa-project.org/?a=commitdiff_plain;h=3fc76a4e6d856e16b977bc637020f1fe17475d56;p=alsa-utils.git Fixed count overflow problem --- diff --git a/aplay/aplay.c b/aplay/aplay.c index c04b477..0bfc1b1 100644 --- a/aplay/aplay.c +++ b/aplay/aplay.c @@ -1756,6 +1756,8 @@ static void capture(char *name) fdcount = 0; count = calc_count(); count += count % 2; + if (count == 0) + count -= 2; /* WAVE-file should be even (I'm not sure), but wasting one byte isn't a problem (this can only be in 8 bit mono) */ if (fmt_rec_table[file_type].start)