Show a patch.

GET /api/1.1/patches/20120/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 20120,
    "url": "https://patchwork.libcamera.org/api/1.1/patches/20120/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/20120/",
    "project": {
        "id": 1,
        "url": "https://patchwork.libcamera.org/api/1.1/projects/1/?format=api",
        "name": "libcamera",
        "link_name": "libcamera",
        "list_id": "libcamera_core",
        "list_email": "libcamera-devel@lists.libcamera.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": ""
    },
    "msgid": "<20240529154341.10426-3-laurent.pinchart@ideasonboard.com>",
    "date": "2024-05-29T15:43:37",
    "name": "[v2,2/6] test: fence: Turn class member variable into local variable",
    "commit_ref": "c44457957e04b4aba18849c94b51c6a69e6801b3",
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "b41b3fbfd22fca8160f9766aa89f7db106583eb8",
    "submitter": {
        "id": 2,
        "url": "https://patchwork.libcamera.org/api/1.1/people/2/?format=api",
        "name": "Laurent Pinchart",
        "email": "laurent.pinchart@ideasonboard.com"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/20120/mbox/",
    "series": [
        {
            "id": 4333,
            "url": "https://patchwork.libcamera.org/api/1.1/series/4333/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=4333",
            "date": "2024-05-29T15:43:35",
            "name": "vimc scaling improvements",
            "version": 2,
            "mbox": "https://patchwork.libcamera.org/series/4333/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/20120/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/20120/checks/",
    "tags": {},
    "headers": {
        "Return-Path": "<libcamera-devel-bounces@lists.libcamera.org>",
        "X-Original-To": "parsemail@patchwork.libcamera.org",
        "Delivered-To": "parsemail@patchwork.libcamera.org",
        "Received": [
            "from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id D8A18BDE6B\n\tfor <parsemail@patchwork.libcamera.org>;\n\tWed, 29 May 2024 15:44:01 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 6249C634C0;\n\tWed, 29 May 2024 17:44:01 +0200 (CEST)",
            "from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id F02296347E\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 29 May 2024 17:43:55 +0200 (CEST)",
            "from pendragon.ideasonboard.com (81-175-209-231.bb.dnainternet.fi\n\t[81.175.209.231])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 3F8394AB\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 29 May 2024 17:43:52 +0200 (CEST)"
        ],
        "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"gYIxZEMV\"; dkim-atps=neutral",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1716997432;\n\tbh=aWyNEfpdBLxbG3criPCarWk/z+V33hVRZwveudno5xg=;\n\th=From:To:Subject:Date:In-Reply-To:References:From;\n\tb=gYIxZEMV84ikaqMFxnAvp0cEolhVh7xFsJnhtBoZXNC/N33T/xtB6UuBf5NPQ+4us\n\t7ekpK3/s/r8SdvDnxTQJbn0VNgdw7dQiuyem6k/PfthvsVg7ZS6LrVoVNHXxkiZGrP\n\tii6S9UicflLIgGDc4+b6M0N/LcrAJ15frQ8NfXZ4=",
        "From": "Laurent Pinchart <laurent.pinchart@ideasonboard.com>",
        "To": "libcamera-devel@lists.libcamera.org",
        "Subject": "[PATCH v2 2/6] test: fence: Turn class member variable into local\n\tvariable",
        "Date": "Wed, 29 May 2024 18:43:37 +0300",
        "Message-ID": "<20240529154341.10426-3-laurent.pinchart@ideasonboard.com>",
        "X-Mailer": "git-send-email 2.44.1",
        "In-Reply-To": "<20240529154341.10426-1-laurent.pinchart@ideasonboard.com>",
        "References": "<20240529154341.10426-1-laurent.pinchart@ideasonboard.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "X-BeenThere": "libcamera-devel@lists.libcamera.org",
        "X-Mailman-Version": "2.1.29",
        "Precedence": "list",
        "List-Id": "<libcamera-devel.lists.libcamera.org>",
        "List-Unsubscribe": "<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>",
        "List-Archive": "<https://lists.libcamera.org/pipermail/libcamera-devel/>",
        "List-Post": "<mailto:libcamera-devel@lists.libcamera.org>",
        "List-Help": "<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>",
        "List-Subscribe": "<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>",
        "Errors-To": "libcamera-devel-bounces@lists.libcamera.org",
        "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"
    },
    "content": "The fence_ class member variable is only used locally in the\nFenceTest::run() function. Make it a local variable.\n\nSigned-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\nReviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n---\n test/fence.cpp | 8 ++++----\n 1 file changed, 4 insertions(+), 4 deletions(-)",
    "diff": "diff --git a/test/fence.cpp b/test/fence.cpp\nindex ada650ff2417..c282886287aa 100644\n--- a/test/fence.cpp\n+++ b/test/fence.cpp\n@@ -43,7 +43,6 @@ private:\n \n \tvoid signalFence();\n \n-\tstd::unique_ptr<Fence> fence_;\n \tEventDispatcher *dispatcher_;\n \tUniqueFD eventFd_;\n \tUniqueFD eventFd2_;\n@@ -274,13 +273,14 @@ int FenceTest::run()\n \t\tint ret;\n \t\tif (i == expiredRequestId_) {\n \t\t\t/* This request will have a fence, and it will expire. */\n-\t\t\tfence_ = std::make_unique<Fence>(std::move(eventFd_));\n-\t\t\tif (!fence_->isValid()) {\n+\t\t\tstd::unique_ptr<Fence> fence =\n+\t\t\t\tstd::make_unique<Fence>(std::move(eventFd_));\n+\t\t\tif (!fence->isValid()) {\n \t\t\t\tcerr << \"Fence should be valid\" << endl;\n \t\t\t\treturn TestFail;\n \t\t\t}\n \n-\t\t\tret = request->addBuffer(stream_, buffer.get(), std::move(fence_));\n+\t\t\tret = request->addBuffer(stream_, buffer.get(), std::move(fence));\n \t\t} else {\n \t\t\t/* All other requests will have no Fence. */\n \t\t\tret = request->addBuffer(stream_, buffer.get());\n",
    "prefixes": [
        "v2",
        "2/6"
    ]
}