summaryrefslogtreecommitdiff
path: root/libavcodec/vc1.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2012-03-27 11:52:08 +0200
committerMichael Niedermayer <michaelni@gmx.at>2012-03-27 11:59:39 +0200
commit6999f8bcf56bb167124bf85bdaa89090acdd5d9c (patch)
tree5bfb541bec48db787901f2441bd887d3629737ea /libavcodec/vc1.c
parentab31db06103c6ac0c1bd1f9fdfa93220d8801e19 (diff)
parent904100e5fc13dacc954b1d093bf87bc44f4e7a7b (diff)
Merge remote-tracking branch 'qatar/master'
* qatar/master: make av_interleaved_write_frame() flush packets when pkt is NULL mpegts: Fix dead error checks vc1: Do not read from array if index is invalid. targa: convert to bytestream2. rv34: set mb_num_left to 0 after finishing a frame Conflicts: libavcodec/targa.c libavcodec/vc1data.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/vc1.c')
-rw-r--r--libavcodec/vc1.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/vc1.c b/libavcodec/vc1.c
index 937fc1ace1..21bdced674 100644
--- a/libavcodec/vc1.c
+++ b/libavcodec/vc1.c
@@ -493,7 +493,7 @@ static int decode_sequence_header_adv(VC1Context *v, GetBitContext *gb)
int nr, dr;
nr = get_bits(gb, 8);
dr = get_bits(gb, 4);
- if (nr && nr < 8 && dr && dr < 3) {
+ if (nr > 0 && nr < 8 && dr > 0 && dr < 3) {
v->s.avctx->time_base.num = ff_vc1_fps_dr[dr - 1];
v->s.avctx->time_base.den = ff_vc1_fps_nr[nr - 1] * 1000;
}