Mercurial > libavcodec.hg
changeset 10593:46cb472ecc1e libavcodec
Make sure field_select is not set to nonsensical values even if unused.
Fixed an assert failure.
author | michael |
---|---|
date | Sun, 29 Nov 2009 01:50:43 +0000 |
parents | 69feacc1a220 |
children | 73779b8e6c5f |
files | mpeg12.c |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mpeg12.c Sat Nov 28 23:17:46 2009 +0000 +++ b/mpeg12.c Sun Nov 29 01:50:43 2009 +0000 @@ -1847,7 +1847,7 @@ s->mv[0][0][0] = s->mv[0][0][1] = 0; s->last_mv[0][0][0] = s->last_mv[0][0][1] = 0; s->last_mv[0][1][0] = s->last_mv[0][1][1] = 0; - s->field_select[0][0]= s->picture_structure - 1; + s->field_select[0][0]= (s->picture_structure - 1) & 1; } else { /* if B type, reuse previous vectors and directions */ s->mv[0][0][0] = s->last_mv[0][0][0];