mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-27 01:42:20 +00:00
avcodec/frame_thread_encoder: Remove redundant memcpy
In case the underlying AVCodec has no private class, the private data of both the main as well as each worker AVCodecContext is just zeroed (the codec's init function has not been called on any of them and without a private class there is no way to legitimately set anything before the aforementioned init function). Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
parent
3f6e715336
commit
cbf6047c83
@ -215,8 +215,6 @@ int ff_frame_thread_encoder_init(AVCodecContext *avctx)
|
||||
int ret = av_opt_copy(thread_avctx->priv_data, avctx->priv_data);
|
||||
if (ret < 0)
|
||||
goto fail;
|
||||
} else if (avctx->codec->priv_data_size) {
|
||||
memcpy(thread_avctx->priv_data, avctx->priv_data, avctx->codec->priv_data_size);
|
||||
}
|
||||
thread_avctx->thread_count = 1;
|
||||
thread_avctx->active_thread_type &= ~FF_THREAD_FRAME;
|
||||
|
Loading…
Reference in New Issue
Block a user