1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-08-15 14:13:16 +02:00

dnn/dnn_backend_native_layer_conv2d: Check allocation

Reviewed-by: Guo, Yejun <yejun.guo@intel.com>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
This commit is contained in:
Andreas Rheinhardt
2021-03-10 17:42:43 +01:00
parent d14ae74064
commit c2fef8f16c

View File

@@ -228,6 +228,8 @@ int ff_dnn_execute_layer_conv2d(DnnOperand *operands, const int32_t *input_opera
#if HAVE_PTHREAD_CANCEL
thread_param = av_malloc_array(thread_num, sizeof(*thread_param));
if (!thread_param)
return DNN_ERROR;
thread_stride = (height - pad_size * 2) / thread_num;
//create threads
for (int i = 0; i < thread_num; i++){