summaryrefslogtreecommitdiff
path: root/libavcodec/vc1.c
diff options
context:
space:
mode:
authorKostya Shishkov <kostya.shishkov@gmail.com>2013-11-25 14:04:41 +0100
committerLuca Barbato <lu_zero@gentoo.org>2013-11-26 00:34:12 +0100
commitde44dfc7c0ec02bda7d846ef713145c890bfae3f (patch)
tree476deaa81131d3b2951e7b8a5257ca055c7ac14e /libavcodec/vc1.c
parent5145ccf02b1771233c1b33b5bd20a8bd94a3c15c (diff)
vc1: Reset numref if fieldmode is not set
There are samples in the wild with B-frames and P-frames with different interlace mode. CC: libav-stable@libav.org Reported-by: Jean-Baptiste Kempf <jb@videolan.org> Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Diffstat (limited to 'libavcodec/vc1.c')
-rw-r--r--libavcodec/vc1.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/vc1.c b/libavcodec/vc1.c
index d6586bfaeb..b7018176b4 100644
--- a/libavcodec/vc1.c
+++ b/libavcodec/vc1.c
@@ -1005,6 +1005,8 @@ int ff_vc1_parse_frame_header_adv(VC1Context *v, GetBitContext* gb)
v->reffield = get_bits1(gb);
v->ref_field_type[0] = v->reffield ^ !v->cur_field_type;
}
+ } else {
+ v->numref = 0;
}
if (v->extended_mv)
v->mvrange = get_unary(gb, 0, 3);