diff --git a/libavcodec/pthread.c b/libavcodec/pthread.c index 2154163c10..0399ea7901 100644 --- a/libavcodec/pthread.c +++ b/libavcodec/pthread.c @@ -239,8 +239,10 @@ static int thread_init(AVCodecContext *avctx) ThreadContext *c; int thread_count = avctx->thread_count; - if (thread_count <= 1) + if (thread_count <= 1) { + avctx->active_thread_type = 0; return 0; + } c = av_mallocz(sizeof(ThreadContext)); if (!c)