1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

avcodec/vorbis: fix decoding of single element huffman trees

Fixes Ticket2893

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2014-03-08 05:13:05 +01:00
parent b918d6e2e6
commit 742d860103

View File

@ -85,6 +85,11 @@ int ff_vorbis_len2vlc(uint8_t *bits, uint32_t *codes, unsigned num)
++p;
for (i = p; (bits[i] == 0) && (i < num); ++i)
;
if (i == num)
return 0;
for (; p < num; ++p) {
if (bits[p] > 32)
return AVERROR_INVALIDDATA;