diff options
author | Dustin Brody <libav@parsoma.net> | 2011-08-16 16:46:34 -0400 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2011-09-22 01:22:21 +0200 |
commit | 056e9efc8e06faed3516b610d8a74484f24ac07f (patch) | |
tree | e6ae3c8a1e7cde278530e89f9eaf490978ed02c7 | |
parent | cf43508eb39bb3749f45d84ded924e1b30794566 (diff) | |
download | ffmpeg-056e9efc8e06faed3516b610d8a74484f24ac07f.tar.gz |
vp6: partially propagate huffman tree building errors during coeff model parsing and fix misspelling
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
(cherry picked from commit f913eeea43078b3b9052efd8d8d29e7b29b39208)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavcodec/vp6.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libavcodec/vp6.c b/libavcodec/vp6.c index 0b26c0461a..d05a3618f7 100644 --- a/libavcodec/vp6.c +++ b/libavcodec/vp6.c @@ -213,8 +213,8 @@ static int vp6_huff_cmp(const void *va, const void *vb) return (a->count - b->count)*16 + (b->sym - a->sym); } -static void vp6_build_huff_tree(VP56Context *s, uint8_t coeff_model[], - const uint8_t *map, unsigned size, VLC *vlc) +static int vp6_build_huff_tree(VP56Context *s, uint8_t coeff_model[], + const uint8_t *map, unsigned size, VLC *vlc) { Node nodes[2*VP6_MAX_HUFF_SIZE], *tmp = &nodes[size]; int a, b, i; @@ -229,9 +229,9 @@ static void vp6_build_huff_tree(VP56Context *s, uint8_t coeff_model[], } free_vlc(vlc); - /* then build the huffman tree accodring to probabilities */ - ff_huff_build_tree(s->avctx, vlc, size, nodes, vp6_huff_cmp, - FF_HUFFMAN_FLAG_HNODE_FIRST); + /* then build the huffman tree according to probabilities */ + return ff_huff_build_tree(s->avctx, vlc, size, nodes, vp6_huff_cmp, + FF_HUFFMAN_FLAG_HNODE_FIRST); } static int vp6_parse_coeff_models(VP56Context *s) |