diff options
author | Kostya Shishkov <kostya.shishkov@gmail.com> | 2011-01-08 19:23:24 +0000 |
---|---|---|
committer | Kostya Shishkov <kostya.shishkov@gmail.com> | 2011-01-08 19:23:24 +0000 |
commit | c392cc0a649dc5d2d4efd9ca11b937222e0d2a12 (patch) | |
tree | 43599b5a9365d0ec98d16efc913caf9c86199752 | |
parent | 15a8bef0b6a5f75189fde4db2bca0842a6de91dd (diff) | |
download | ffmpeg-c392cc0a649dc5d2d4efd9ca11b937222e0d2a12.tar.gz |
Limit number of samples decoded for WavPack mono mode, so decoded samples will
fit into output buffer.
Originally committed as revision 26269 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavcodec/wavpack.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/wavpack.c b/libavcodec/wavpack.c index 779fe80e3e..f78492c924 100644 --- a/libavcodec/wavpack.c +++ b/libavcodec/wavpack.c @@ -630,7 +630,7 @@ static inline int wv_unpack_mono(WavpackContext *s, GetBitContext *gb, void *dst else *dst16++ = wv_get_value_integer(s, &crc_extra_bits, S); count++; - }while(!last && count < s->samples); + }while(!last && count < s->max_samples); s->samples_left -= count; if(!s->samples_left){ |