Commit 357a733f authored by Michael Niedermayer's avatar Michael Niedermayer

Merge commit 'd1b3fabe'

* commit 'd1b3fabe':
  h264: reset first_field if frame_start() fails for missing refs

See: d7599bd8Merged-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parents 06637c92 d1b3fabe
...@@ -3751,8 +3751,11 @@ static int decode_slice_header(H264Context *h, H264Context *h0) ...@@ -3751,8 +3751,11 @@ static int decode_slice_header(H264Context *h, H264Context *h0)
for(i=0; i<FF_ARRAY_ELEMS(h->last_pocs); i++) for(i=0; i<FF_ARRAY_ELEMS(h->last_pocs); i++)
h->last_pocs[i] = INT_MIN; h->last_pocs[i] = INT_MIN;
ret = h264_frame_start(h); ret = h264_frame_start(h);
if (ret < 0) if (ret < 0) {
h0->first_field = 0;
return ret; return ret;
}
h->prev_frame_num++; h->prev_frame_num++;
h->prev_frame_num %= 1 << h->sps.log2_max_frame_num; h->prev_frame_num %= 1 << h->sps.log2_max_frame_num;
h->cur_pic_ptr->frame_num = h->prev_frame_num; h->cur_pic_ptr->frame_num = h->prev_frame_num;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment