From patchwork Wed Oct 7 09:22:38 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 9991 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id 45996BEEDF for ; Wed, 7 Oct 2020 09:23:30 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 131E463CC5; Wed, 7 Oct 2020 11:23:30 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="cJF6sRpv"; dkim-atps=neutral Received: from mail-lf1-x131.google.com (mail-lf1-x131.google.com [IPv6:2a00:1450:4864:20::131]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 41BB663CDC for ; Wed, 7 Oct 2020 11:23:26 +0200 (CEST) Received: by mail-lf1-x131.google.com with SMTP id y11so1477119lfl.5 for ; Wed, 07 Oct 2020 02:23:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=ASlDfRmcZux0WTHlF7DPWJ5JOUsvv/gtOF0gl+qrgJI=; b=cJF6sRpv7BaZglHd6wSngOi9ppQFlXOh9C0k1il12Im+PjXZXSpac2oP5Eki9AnvBv Lqdz7FcPM1q61xv2HUtZEOmVB1bV6C/3Pd3b0RIKD+tJANtzMRGYoRO9GlKUpttL83g4 46kgHM/XW2bsoBcwJhBlmz4n0iJFoEQsaiWXHa4s/yTiPC7c/R2q1TxhI1c/oIcrzCM0 yATuH8tzR8XzpxbbJz8qT5rDH9tByZ+pM2zWVrvAiPhW2WjPYd7nuu5Hxvi+I0nfY3wD LsXvrslqmxepkTKUfQ52SVh4o22jI2vRUwLiqyQQGs7oGu/AJ1CIXXtzd2kUvCCXICXr KJng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=ASlDfRmcZux0WTHlF7DPWJ5JOUsvv/gtOF0gl+qrgJI=; b=Xgx3/2hAXTDf8WOVQjg1TW0ABBS2nw/WF99nPyu9sHo9b2unSuB7L57PuvOCXDMtv5 LKTwuufurJHeaxGKu0Mhtn1wYyt+WR71Y+KnsWpXvz5PUw27jjg1r54+OqJv4lRUwg+T sviNjZLuMfbKbQn3JQ3nG3iEstMWtI+q0pBndJoGZKDOhPpPtKRuG7Rcjumz1oCSPfjd cvpovN7JKYR/wqfeakaW3kulQfKcJ2sInK3tlHe4EShquulgjI3g7kZjOfcxh4Tm+Pc1 OXbzPuZR6TcDscJuaqI9Gu+Pe8G7hIhlVRkhZLpzCZcse/mCSicIV4lbXo6ZupF1lsBI ndbg== X-Gm-Message-State: AOAM53028tCnKI+blrL+JoolOTyfCjULjeNg49fxM9ahM3GrmgX2fZmg AwBHQ6Cfj4dZenf89jb9t+F5mbypu4is7g== X-Google-Smtp-Source: ABdhPJxG8UCejirYznb2qNBS6RMx58yyMihVKuJ8pqs5yg2OaWY0xQ0K6wpITNOAriFZKpEmAt7OFg== X-Received: by 2002:a19:8c52:: with SMTP id i18mr641842lfj.115.1602062604484; Wed, 07 Oct 2020 02:23:24 -0700 (PDT) Received: from deskari.lan (91-152-83-50.elisa-laajakaista.fi. [91.152.83.50]) by smtp.gmail.com with ESMTPSA id n26sm258341ljg.133.2020.10.07.02.23.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Oct 2020 02:23:23 -0700 (PDT) From: Tomi Valkeinen To: libcamera-devel@lists.libcamera.org Date: Wed, 7 Oct 2020 12:22:38 +0300 Message-Id: <20201007092239.41704-3-tomi.valkeinen@iki.fi> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20201007092239.41704-1-tomi.valkeinen@iki.fi> References: <20201007092239.41704-1-tomi.valkeinen@iki.fi> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH 3/4] cam: fix use of uninitialized field X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Tomi Valkeinen Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" Initialize last_ to 0 to avoid uninitialized use. Signed-off-by: Tomi Valkeinen Reviewed-by: Kieran Bingham Reviewed-by: Laurent Pinchart Reviewed-by: Niklas Söderlund --- src/cam/capture.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cam/capture.cpp b/src/cam/capture.cpp index 5510c00..995614a 100644 --- a/src/cam/capture.cpp +++ b/src/cam/capture.cpp @@ -17,7 +17,7 @@ using namespace libcamera; Capture::Capture(std::shared_ptr camera, CameraConfiguration *config, EventLoop *loop) - : camera_(camera), config_(config), writer_(nullptr), loop_(loop), + : camera_(camera), config_(config), writer_(nullptr), last_(0), loop_(loop), captureCount_(0), captureLimit_(0) { }