avformat/wavdec: Do not discard sample_count due to rounding

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
Michael Niedermayer 2015-08-13 12:13:51 +02:00
parent 1bbb5ea10d
commit 4ec4454ccf
1 changed files with 1 additions and 1 deletions

View File

@ -435,7 +435,7 @@ break_loop:
}
if ( data_size > 0 && sample_count && st->codec->channels
&& (data_size << 3) / sample_count / st->codec->channels > st->codec->bits_per_coded_sample) {
&& (data_size << 3) / sample_count / st->codec->channels > st->codec->bits_per_coded_sample + 1) {
av_log(s, AV_LOG_WARNING, "ignoring wrong sample_count %"PRId64"\n", sample_count);
sample_count = 0;
}