From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id 0C5AD476D8 for ; Thu, 21 Sep 2023 01:27:08 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 7CD1B68C8ED; Thu, 21 Sep 2023 04:26:53 +0300 (EEST) Received: from mgamail.intel.com (mgamail.intel.com [134.134.136.20]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 867E568C378 for ; Thu, 21 Sep 2023 04:26:46 +0300 (EEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1695259611; x=1726795611; h=from:to:subject:date:message-id:in-reply-to:references: mime-version:content-transfer-encoding; bh=gRJBrY+gH9zsE1C5n70x4p5LXa2QAHNCe0vbFOx70Aw=; b=AuLsHNaNfs6cXAg1FJ6GWHsFVntD6tCxMjfci2u/Q/Jv7zeQlIldIte6 Zcr103BMiX0PgaXq0GYJFq5YCspbxgEbTsa3fhU9QefMjzMuKByzOeqUK Nw9jLi1AUxH8hcY1VuQU3INcS+q+jeiyxxE+uhy3xOGVh8XddWEFwALmU F+/szm/9ADULGEzZdBSZpgSTvHBVjG0JVsfaXsuqAl6WyWkiG8gQ3mpOF lphhceE8jqyiQAMrmgPDpEo5VmeVLuhIsQdNq0ovAPi9xknWCLHhtYZMw XQodM9SxV5rV5bMDJa+fdE1+Tg//pl+1M78F1Yva8T/spBkzEz3Swn2c3 g==; X-IronPort-AV: E=McAfee;i="6600,9927,10839"; a="370700950" X-IronPort-AV: E=Sophos;i="6.03,162,1694761200"; d="scan'208";a="370700950" Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Sep 2023 18:26:37 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10839"; a="781943214" X-IronPort-AV: E=Sophos;i="6.03,162,1694761200"; d="scan'208";a="781943214" Received: from wenbin-z390-aorus-ultra.sh.intel.com ([10.239.156.43]) by orsmga001.jf.intel.com with ESMTP; 20 Sep 2023 18:26:37 -0700 From: wenbin.chen-at-intel.com@ffmpeg.org To: ffmpeg-devel@ffmpeg.org Date: Thu, 21 Sep 2023 09:26:33 +0800 Message-Id: <20230921012633.16241-3-wenbin.chen@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230921012633.16241-1-wenbin.chen@intel.com> References: <20230921012633.16241-1-wenbin.chen@intel.com> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH v2 3/3] libavfilter/dnn: Initialze DNNData variables X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: From: Wenbin Chen Signed-off-by: Wenbin Chen --- libavfilter/dnn/dnn_backend_tf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavfilter/dnn/dnn_backend_tf.c b/libavfilter/dnn/dnn_backend_tf.c index b521de7fbe..25046b58d9 100644 --- a/libavfilter/dnn/dnn_backend_tf.c +++ b/libavfilter/dnn/dnn_backend_tf.c @@ -622,7 +622,7 @@ err: } static int fill_model_input_tf(TFModel *tf_model, TFRequestItem *request) { - DNNData input; + DNNData input = { 0 }; LastLevelTaskItem *lltask; TaskItem *task; TFInferRequest *infer_request = NULL; @@ -724,7 +724,7 @@ static void infer_completion_callback(void *args) { TFModel *tf_model = task->model; TFContext *ctx = &tf_model->ctx; - outputs = av_malloc_array(task->nb_output, sizeof(*outputs)); + outputs = av_calloc(task->nb_output, sizeof(*outputs)); if (!outputs) { av_log(ctx, AV_LOG_ERROR, "Failed to allocate memory for *outputs\n"); goto err; -- 2.34.1 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".