mirror of https://git.ffmpeg.org/ffmpeg.git
avcodec/pthread_frame: Use av_mallocz_array()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
007547b282
commit
ab1e191720
|
@ -631,7 +631,7 @@ int ff_frame_thread_init(AVCodecContext *avctx)
|
|||
|
||||
avctx->internal->thread_ctx = fctx = av_mallocz(sizeof(FrameThreadContext));
|
||||
|
||||
fctx->threads = av_mallocz(sizeof(PerThreadContext) * thread_count);
|
||||
fctx->threads = av_mallocz_array(thread_count, sizeof(PerThreadContext));
|
||||
pthread_mutex_init(&fctx->buffer_mutex, NULL);
|
||||
fctx->delaying = 1;
|
||||
|
||||
|
|
Loading…
Reference in New Issue