From patchwork Sun Jun 11 14:05:45 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Timo Rothenpieler X-Patchwork-Id: 3911 Delivered-To: ffmpegpatchwork@gmail.com Received: by 10.103.10.195 with SMTP id 186csp511918vsk; Sun, 11 Jun 2017 07:06:13 -0700 (PDT) X-Received: by 10.28.28.146 with SMTP id c140mr5341370wmc.122.1497189973505; Sun, 11 Jun 2017 07:06:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1497189973; cv=none; d=google.com; s=arc-20160816; b=d+u2pLKPG085ekY0Kq6xAKJvMXgvBPjvGQ5ojdwnhp3Tkt051Qy6HLhMDqvkwbrvMA Ca3peT9hDyvs4J8TMsO3KnuzHHKtDbk0RewIDvJnctbtnd7FWykIn4KVICc85ZZDBEv/ j0Cztt4QGh2MN7oW+HjZcD+g1dEfk5CYIY/dAH/olrHAM/M1XknQr+hHCa9k8nkM+Qxz flisKTIodV+dHRLSYb9XGzIY02a1Iotv4tw2b0FknY/PpTCk47eK/SzSrGHmj91kZOxm 1/YU+k+GBrhUllqWY5Vx3CK1Axjt2rBz8Jm0GOuLvvIC6kXPOunmmzxhzrrKNfVxzBnH /m4w== 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:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to:arc-authentication-results; bh=b767yuOV+r+0n2phJH1MvmDbeVf2Q54YqAud4RaqZC8=; b=FlXzfoTVrVZs2p2db9Bc7CD2+GgMjF0802cmF5hIyUc6mkZhzT0t6PZQm8yBKgouiK dH2TJ642+ByNtW0YKh088bbaEuRd95jnLGprVd6U1wDHnhkoMFj5ouUSlIcoUFHkEXd5 U44ZIcDGWMAW3ej0jfRIF3Qb3np+rpspT5y1joJgWO76pLRjirRHXMY19v0OMu+I4KjK Za2ZID0b9tR95/o+jeTrT2t6Fm6l9UjNdp2Ix85e0c7x3ec9oIO4+2uBtYIyZvExV2M7 fUW8p4uRl64UZ9/aVR32cqu436uIE+jzcDtrsWX9O+k6rNabewiqHKiuygi1Jn4BiHpZ oGcQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@rothenpieler.org; 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 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id 32si6872007wrd.260.2017.06.11.07.06.12; Sun, 11 Jun 2017 07:06:13 -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=@rothenpieler.org; 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 Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id E4877689DD6; Sun, 11 Jun 2017 17:06:07 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from btbn.de (btbn.de [5.9.118.179]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id AA1F3688262 for ; Sun, 11 Jun 2017 17:06:01 +0300 (EEST) Received: from localhost.localdomain (unknown [IPv6:2a02:8109:43f:959c:ba97:5aff:fe10:ec69]) by btbn.de (Postfix) with ESMTPSA id D33EF6A513; Sun, 11 Jun 2017 16:06:02 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=rothenpieler.org; s=mail; t=1497189962; bh=qrCNrSDNEbbhIqQNijbUuVVHQODwHnQ5RU+hercco3c=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=FoHecZJIRVqyfJoMrE9q681NqVaBpgg70lwnm+VLeDjOBwoIwSafo0PfPSbqrEo4i 8o26qw+WSTtwzcokYo8FNzbdGIYM/2V7GeEwxBFhe5H3P9X5OaeZfAgx6i0SKG/tSX 67/RtAeiBUueeVKG1hpY1gJMZ9hLq6NyxPIDsSdI= From: Timo Rothenpieler To: ffmpeg-devel@ffmpeg.org Date: Sun, 11 Jun 2017 16:05:45 +0200 Message-Id: <20170611140551.11844-3-timo@rothenpieler.org> X-Mailer: git-send-email 2.13.0 In-Reply-To: <20170611140551.11844-1-timo@rothenpieler.org> References: <20170611140551.11844-1-timo@rothenpieler.org> Subject: [FFmpeg-devel] [PATCH 03/11] libavutil/opencl: fix potentiall nul dereference 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: Timo Rothenpieler MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Fixes CID 1396840 --- libavutil/opencl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/opencl.c b/libavutil/opencl.c index af35770e06..202756516b 100644 --- a/libavutil/opencl.c +++ b/libavutil/opencl.c @@ -169,7 +169,7 @@ const char *av_opencl_errstr(cl_int status) static void free_device_list(AVOpenCLDeviceList *device_list) { int i, j; - if (!device_list) + if (!device_list || !device_list->platform_node) return; for (i = 0; i < device_list->platform_num; i++) { if (!device_list->platform_node[i])