From patchwork Thu Sep 13 07:49:52 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zhao Zhili X-Patchwork-Id: 10313 Delivered-To: ffmpegpatchwork@gmail.com Received: by 2002:a02:12c4:0:0:0:0:0 with SMTP id 65-v6csp292669jap; Thu, 13 Sep 2018 00:50:43 -0700 (PDT) X-Google-Smtp-Source: ANB0VdYHm3nPanL19P4yIzTPn6Irzdi8Fla2QRv0oM3yCRsTTZR9UspbgDdPK8tAR57dV/K1RuUz X-Received: by 2002:a7b:c1ca:: with SMTP id a10-v6mr4084136wmj.35.1536825043528; Thu, 13 Sep 2018 00:50:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536825043; cv=none; d=google.com; s=arc-20160816; b=WPhr5EYytgaoFfFJM3hFhb5vFN1Ca77nNhvhvdh7hSt8RPLO317sjmvbFPQuX7vsfR 3by5hyraBADMVJj82DNy1zr+nhvsdKRKQ8nL47pu5Ri+LLAuykdMDjfmxf4NM5NToai5 qNF7XFAyCtxn0c980JFrOeYF39tMk4DiPdgy8Q86f9DBOYBxhzrdSzqQCMZYuHrZHjSf DYqH1v2nHFFaWszqYUTZs0yc2/zRkyMPnICnDFJhsMOEvVOzMwrC/2HqKCeRkROd+qDG Z6rn2wwUnoV1JmbRH4JR4/kUnVz167Fp5tYWsy2uRAZ48yUxp6m3KITezAD+PKdzi8H7 iodw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version:cc:reply-to :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:feedback-id:references:in-reply-to :message-id:date:to:from:dkim-signature:delivered-to; bh=IuwTCi2NNXR7/OoJbC6w+q+UnZVcWWjpQX85Iz4RCAQ=; b=pkOl1mk84iw4fVM1J18LwvxKxF6u9nAGdduFrYRWtwTkwJHAH6OQUS+N+fe6qhTkCe +5cWYQS7hXJcR3vosW2WOFg1U8nro67tzQAVamkkPHB16YWoM+W29Eh/aj9HJa2+WXQl tn/PkVsESg3qxeMBC+IreaZQ2NmaOe1gIESVNGdznqvichyUw8e/8LI1vseoqBVaLSvX m46jgilaTJINj+M2uRkSitcgPA3Tn2viWg638V5ude0jHXemWFhjUgGkpwEN2/oX5hVP 8pyYWswIyJRlHUOI2UG/Ed1IuZpZHCoAwlcvszwqH6L2bjveGpF43KjilcphNxcwk2ij Y7zw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@foxmail.com header.s=s201512 header.b=PUR9A3MU; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=foxmail.com Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id b4-v6si2887238wri.17.2018.09.13.00.50.43; Thu, 13 Sep 2018 00:50:43 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@foxmail.com header.s=s201512 header.b=PUR9A3MU; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=foxmail.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 4B30968A56B; Thu, 13 Sep 2018 10:50:23 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from smtpproxy19.qq.com (smtpproxy19.qq.com [184.105.206.84]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 25051689E93 for ; Thu, 13 Sep 2018 10:50:15 +0300 (EEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=foxmail.com; s=s201512; t=1536825010; bh=5oFnMuKSKksRpjBMgh3pq9f682S3anLaY06XxZIiFhA=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References; b=PUR9A3MUFMYxzsOVRlaChBbvsmu6nWMpRu5WqW9nwXOlKl9cZLSVWLrEm/CdvXdq7 V83Uooya80vXWEv82FLhXxnG9RnHDd+YqbUCNmQGijQg4DIfqrrQ6A3S8YezzuFOLT Ukyu/FMEGcq7170MAqEdZEQr/NWuWsfBqu3tSaT0= X-QQ-mid: esmtp3t1536825010t6234o58a Received: from localhost.localdomain (unknown [119.145.5.45]) by esmtp4.qq.com (ESMTP) with id ; Thu, 13 Sep 2018 15:50:09 +0800 (CST) X-QQ-SSF: A1000000000000F0FF1003000000001 X-QQ-FEAT: a+7Y0Sw85TjspRUMDMMH0C39AGOmDwfyYxvEy9lybfPopo5yk2dIhGVabKhBI iFf+mUXNAQpZExc0a9YTUGAiSPxxUtmjB1NAb3g3DyYC5JpwQa1bCH0QSDdsXuW/ric0yFg 8zfU6+pahFLz5woQ+cpeVZNbbgoUPv9eqjLFgf75+T8ApZNMkRg9C3mhYybSxTJwrDbMd4A dPXb9ynncs5V0RGzSvaLydSIa0BfH1lSUPloC8xE/PkfPojYhDhJQL/l86XZA9TBHZVGkbA nqRoIpA3b7jDa0aW+HmSzraKY2S9rbnOZdTg== X-QQ-GoodBg: 0 From: Zhao Zhili To: ffmpeg-devel@ffmpeg.org Date: Thu, 13 Sep 2018 15:49:52 +0800 Message-Id: <20180913074952.2873-3-quinkblack@foxmail.com> X-Mailer: git-send-email 2.9.5 In-Reply-To: <20180913074952.2873-1-quinkblack@foxmail.com> References: <20180913074952.2873-1-quinkblack@foxmail.com> X-QQ-SENDSIZE: 520 Feedback-ID: esmtp:foxmail.com:bgforeign:bgforeign4 X-QQ-Bgrelay: 1 Subject: [FFmpeg-devel] [PATCH 3/3] avfilter/dnn_backend_native: fix memleak X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 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 Cc: Zhao Zhili MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" --- libavfilter/dnn_backend_native.c | 1 + 1 file changed, 1 insertion(+) diff --git a/libavfilter/dnn_backend_native.c b/libavfilter/dnn_backend_native.c index 7ed155d..3108185 100644 --- a/libavfilter/dnn_backend_native.c +++ b/libavfilter/dnn_backend_native.c @@ -489,6 +489,7 @@ void ff_dnn_free_model_native(DNNModel **model) } av_freep(&network->layers[layer].params); } + av_freep(&network->layers); av_freep(&network); av_freep(model); }