threads: set thread_count to 1 when thread support is disabled
This commit is contained in:
parent
b4d44a45f9
commit
b6064d9a59
@ -710,6 +710,8 @@ int attribute_align_arg avcodec_open2(AVCodecContext *avctx, AVCodec *codec, AVD
|
|||||||
goto free_and_end;
|
goto free_and_end;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (!HAVE_THREADS && !(codec->capabilities & CODEC_CAP_AUTO_THREADS))
|
||||||
|
avctx->thread_count = 1;
|
||||||
|
|
||||||
if (avctx->codec->max_lowres < avctx->lowres) {
|
if (avctx->codec->max_lowres < avctx->lowres) {
|
||||||
av_log(avctx, AV_LOG_ERROR, "The maximum value for lowres supported by the decoder is %d\n",
|
av_log(avctx, AV_LOG_ERROR, "The maximum value for lowres supported by the decoder is %d\n",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user