Commit e344e651 authored by Anton Khirnov's avatar Anton Khirnov

h264dec: do not call finish_setup() if we have not started a frame

Found-By: 's avatarJan Ruge <jan.s.ruge@gmail.com>
Bug-Id: 952
parent 76f7e70a
......@@ -557,7 +557,7 @@ static int decode_nal_units(H264Context *h, const uint8_t *buf, int buf_size)
break;
if (avctx->active_thread_type & FF_THREAD_FRAME && !h->avctx->hwaccel &&
i >= nals_needed && !h->setup_finished) {
i >= nals_needed && !h->setup_finished && h->cur_pic_ptr) {
ff_thread_finish_setup(avctx);
h->setup_finished = 1;
}
......
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