pthread: make ff_thread_release_buffer idempotent.

I.e. don't do anything on already released frames.
pull/9/head
Anton Khirnov 12 years ago
parent 729b37149c
commit e6b1c3bbe7
  1. 3
      libavcodec/pthread.c

@ -975,6 +975,9 @@ void ff_thread_release_buffer(AVCodecContext *avctx, AVFrame *f)
PerThreadContext *p = avctx->thread_opaque;
FrameThreadContext *fctx;
if (!f->data[0])
return;
if (!(avctx->active_thread_type&FF_THREAD_FRAME)) {
avctx->release_buffer(avctx, f);
return;

Loading…
Cancel
Save