From patchwork Sun Jun 11 14:05:48 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Timo Rothenpieler X-Patchwork-Id: 3916 Delivered-To: ffmpegpatchwork@gmail.com Received: by 10.103.10.195 with SMTP id 186csp512235vsk; Sun, 11 Jun 2017 07:07:07 -0700 (PDT) X-Received: by 10.28.6.213 with SMTP id 204mr5167730wmg.15.1497190027570; Sun, 11 Jun 2017 07:07:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1497190027; cv=none; d=google.com; s=arc-20160816; b=SEM0jneT/dw8+W2xql91XmhL1Vd/37eiH2Blha4Ced0fZv3YBa+Jsg9llwKTYeBoef OrG4UXw1bySbgaBqsIx1STrvXP+HDlaFyI43cIbaWk5WYbg5iMkVgD/A7+Lc4hs8pHwD Raxj0YNsNI7lR/k0NuL4RjCovIPnKjpDl3TDC6t/ereYO2OjH13gYwu7vEBo5UV1y+EN 8MygJuD+6Av4oKbYS/hUvp0Nq+9nA/mcLoBH5dDFr+9qSQUtqw6HtiG2V8XHFTT5RaR1 RoWnVqHEYCJdKc7BlHaNLZ9/xdqa2biRu2uo0a7tfxaXkETdkU+79fRc4759/YVusoqx Lp4A== 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=PtYGopkANwB+QRTAJg1UCJWzyNHmHdG3B7SSjhSZCQU=; b=v5fXysOy9sdDmggTGkK/7yohwG8UE6DifwRLmXehqFg8hipwO4P45wTGaOyyVRD3FR WzrjTjc3WdPz/l5JKzJaLZ7OGsPY6iIDJ2hPpLYfydlzpEyLshtDIlD/gzifrtQsaZwl WzYqgMNPLVXracUVYM+Cm8A4OcKLfwcVj6d6U75oVfc6wMdqARgvGMh67VeK/BqWrQdZ f/z3p1o6RiZdiV7A2O7DFqXq2i0dDOTKsCS263zqhhzRG4lroxJ4LugvxlW1tJEuiOS8 6hKsYZoWYiTEzM59XP6mUy54A90KbmWxPPd3JpSuxTH31M18AGbs6rhWutSvUnF3qA62 JXxA== 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 j7si6575173wre.45.2017.06.11.07.07.07; Sun, 11 Jun 2017 07:07:07 -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 39B8C689EC2; Sun, 11 Jun 2017 17:06:10 +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 27FE1688262 for ; Sun, 11 Jun 2017 17:06:07 +0300 (EEST) Received: from localhost.localdomain (unknown [IPv6:2a02:8109:43f:959c:ba97:5aff:fe10:ec69]) by btbn.de (Postfix) with ESMTPSA id 53EDA6A51D; Sun, 11 Jun 2017 16:06:03 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=rothenpieler.org; s=mail; t=1497189963; bh=9LuKpF8xV7fJhRYJU2ADDNUkFqme9HGaxhxJld3jZX4=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=wB4tF5q+M+h2nV/eSKUQt+GIgiHfCcKCKzKrIWyE/Hsufa6PVWMAmpxQdMz3hRuiI AQWnjdnYjK9133Bs+RscWhw8Ek4s7PBzQuPLD1uREmVlhRYVekHeW+YziaP0w73swA 2lvXi7St6ia2GpXeKFQaHNAF38Rl/6pUp08Lnl0s= From: Timo Rothenpieler To: ffmpeg-devel@ffmpeg.org Date: Sun, 11 Jun 2017 16:05:48 +0200 Message-Id: <20170611140551.11844-6-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 06/11] avcodec/vaapi_encode: fix potential uninitialized read 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 1400440 --- libavcodec/vaapi_encode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/vaapi_encode.c b/libavcodec/vaapi_encode.c index 7e9c00f51d..9336bbecd4 100644 --- a/libavcodec/vaapi_encode.c +++ b/libavcodec/vaapi_encode.c @@ -738,7 +738,7 @@ fail: static int vaapi_encode_truncate_gop(AVCodecContext *avctx) { VAAPIEncodeContext *ctx = avctx->priv_data; - VAAPIEncodePicture *pic, *last_pic, *next; + VAAPIEncodePicture *pic, *last_pic = NULL, *next; // Find the last picture we actually have input for. for (pic = ctx->pic_start; pic; pic = pic->next) {