From patchwork Tue Oct 18 09:34:49 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paul Elder X-Patchwork-Id: 17622 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 E43FBC0DA4 for ; Tue, 18 Oct 2022 09:35:00 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 499E662E16; Tue, 18 Oct 2022 11:35:00 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org; s=mail; t=1666085700; bh=8XrFa1Qx3T+LO+RGxcaw/IFr36pdTXJQ+0A8zP9UWFc=; h=To:Date:Subject:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:From; b=Spk8a4YCamLmCapBI2m+7JdOAqw4DSDm+0ffn0yN722V3Z6z+sUdSPs8P3hUlXDgs 7WL9p0GABCvgTyRv1AKTNEFyvjql0MO0oh/SlVF4Ij0wEB7jySbao5AgUCNHAgODbp +dxATliddtT8BmkjMtcY/gI7B+l7QVVWhhl29E76tbeqHbh3Lgvf3lrwRizcidkVgw 7ngJ68n6fvpJy3fD3d0hofKxZyCMZv2m9P7j/WTUUAkabx6Q49kCaEH1/zvHu3/+EB KN7rrcPTLTLIhX69hGjEPd1EI58rNh6I1hYHP3vJa2IuSuPCB2Rtc9V1D7h2XFeJJz NnKRlDAhtBDKg== Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 421B862DD1 for ; Tue, 18 Oct 2022 11:34:58 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="fnsOGz7k"; dkim-atps=neutral Received: from pyrite.rasen.tech (h175-177-042-159.catv02.itscom.jp [175.177.42.159]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id D59AF6F3; Tue, 18 Oct 2022 11:34:56 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1666085697; bh=8XrFa1Qx3T+LO+RGxcaw/IFr36pdTXJQ+0A8zP9UWFc=; h=From:To:Cc:Subject:Date:From; b=fnsOGz7kjoIAuglpgSS2hVk4PliPS+K5uPnUpSMhHZ54eSJrCP0o/YGAQkOLtrwig mu2qwv2EdoJowPGR13yIRyndSsbCuFWj6nfJWofR/cIX+Wyqz3TmnAKJT6blNhEVWW Zd/CCpQpE156qdC8OWF4otFNRyxWL+gA64gxqne8= To: libcamera-devel@lists.libcamera.org Date: Tue, 18 Oct 2022 18:34:49 +0900 Message-Id: <20221018093449.3165709-1-paul.elder@ideasonboard.com> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH] ipc: ipa_data_serializer: Use cend() in deserializers 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: , X-Patchwork-Original-From: Paul Elder via libcamera-devel From: Paul Elder Reply-To: Paul Elder Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" The overloaded deserializers functions that called the main deserializer function using iterators used cbegin() but end() instead of cend(). Make all of these use cend() instead. Signed-off-by: Paul Elder Reviewed-by: Laurent Pinchart Reviewed-by: Umang Jain --- include/libcamera/internal/ipa_data_serializer.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/include/libcamera/internal/ipa_data_serializer.h b/include/libcamera/internal/ipa_data_serializer.h index 30bdaebc..54895b87 100644 --- a/include/libcamera/internal/ipa_data_serializer.h +++ b/include/libcamera/internal/ipa_data_serializer.h @@ -134,7 +134,7 @@ public: static std::vector deserialize(std::vector &data, ControlSerializer *cs = nullptr) { - return deserialize(data.cbegin(), data.end(), cs); + return deserialize(data.cbegin(), data.cend(), cs); } static std::vector deserialize(std::vector::const_iterator dataBegin, @@ -142,13 +142,13 @@ public: ControlSerializer *cs = nullptr) { std::vector fds; - return deserialize(dataBegin, dataEnd, fds.cbegin(), fds.end(), cs); + return deserialize(dataBegin, dataEnd, fds.cbegin(), fds.cend(), cs); } static std::vector deserialize(std::vector &data, std::vector &fds, ControlSerializer *cs = nullptr) { - return deserialize(data.cbegin(), data.end(), fds.cbegin(), fds.end(), cs); + return deserialize(data.cbegin(), data.cend(), fds.cbegin(), fds.cend(), cs); } static std::vector deserialize(std::vector::const_iterator dataBegin, @@ -240,7 +240,7 @@ public: static std::map deserialize(std::vector &data, ControlSerializer *cs = nullptr) { - return deserialize(data.cbegin(), data.end(), cs); + return deserialize(data.cbegin(), data.cend(), cs); } static std::map deserialize(std::vector::const_iterator dataBegin, @@ -248,13 +248,13 @@ public: ControlSerializer *cs = nullptr) { std::vector fds; - return deserialize(dataBegin, dataEnd, fds.cbegin(), fds.end(), cs); + return deserialize(dataBegin, dataEnd, fds.cbegin(), fds.cend(), cs); } static std::map deserialize(std::vector &data, std::vector &fds, ControlSerializer *cs = nullptr) { - return deserialize(data.cbegin(), data.end(), fds.cbegin(), fds.end(), cs); + return deserialize(data.cbegin(), data.cend(), fds.cbegin(), fds.cend(), cs); } static std::map deserialize(std::vector::const_iterator dataBegin,