Show a patch.

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

{
    "id": 10054,
    "url": "https://patchwork.libcamera.org/api/patches/10054/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/10054/",
    "project": {
        "id": 1,
        "url": "https://patchwork.libcamera.org/api/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": "<20201013151241.3557005-9-kieran.bingham@ideasonboard.com>",
    "date": "2020-10-13T15:12:39",
    "name": "[libcamera-devel,08/10] ipa: raspberrypi: Re-use iterator variable",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "d59b2ce7ffc0382dbe25e802417fd07b4cc613b4",
    "submitter": {
        "id": 4,
        "url": "https://patchwork.libcamera.org/api/people/4/?format=api",
        "name": "Kieran Bingham",
        "email": "kieran.bingham@ideasonboard.com"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/10054/mbox/",
    "series": [
        {
            "id": 1374,
            "url": "https://patchwork.libcamera.org/api/series/1374/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=1374",
            "date": "2020-10-13T15:12:31",
            "name": "Shadowed Variables",
            "version": 1,
            "mbox": "https://patchwork.libcamera.org/series/1374/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/10054/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/10054/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 AFE27BEEE1\n\tfor <parsemail@patchwork.libcamera.org>;\n\tTue, 13 Oct 2020 15:12:55 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 74AFB60F1E;\n\tTue, 13 Oct 2020 17:12:55 +0200 (CEST)",
            "from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 3154D60DFD\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 13 Oct 2020 17:12:49 +0200 (CEST)",
            "from Q.local (cpc89244-aztw30-2-0-cust3082.18-1.cable.virginm.net\n\t[86.31.172.11])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id C209ABA9;\n\tTue, 13 Oct 2020 17:12:48 +0200 (CEST)"
        ],
        "Authentication-Results": "lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"Iv1hY+KA\"; dkim-atps=neutral",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1602601968;\n\tbh=/3amyfmBVl40XA4/zUIT/CuQHwQ9kzpA0dfssbxbI7w=;\n\th=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n\tb=Iv1hY+KAahrvaHodaPHE7p+czmUZR7GfZDQXPOwPyROekXJbSgHfHATp0dw05OTZb\n\tx+RvuYNmH9QG4N5jKaDF0K0rP+cBxQx8Xy0YqD2EOQXYcy2t9oos0DwuUGa/YDb8G5\n\twsQPkyrhIfyLr5Lo9CVQAH8j11bcoOldPYZw5Y9M=",
        "From": "Kieran Bingham <kieran.bingham@ideasonboard.com>",
        "To": "libcamera devel <libcamera-devel@lists.libcamera.org>",
        "Date": "Tue, 13 Oct 2020 16:12:39 +0100",
        "Message-Id": "<20201013151241.3557005-9-kieran.bingham@ideasonboard.com>",
        "X-Mailer": "git-send-email 2.25.1",
        "In-Reply-To": "<20201013151241.3557005-1-kieran.bingham@ideasonboard.com>",
        "References": "<20201013151241.3557005-1-kieran.bingham@ideasonboard.com>",
        "MIME-Version": "1.0",
        "Subject": "[libcamera-devel] [PATCH 08/10] ipa: raspberrypi: Re-use iterator\n\tvariable",
        "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>",
        "Content-Type": "text/plain; charset=\"us-ascii\"",
        "Content-Transfer-Encoding": "7bit",
        "Errors-To": "libcamera-devel-bounces@lists.libcamera.org",
        "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"
    },
    "content": "The function gauss_seidel2_SOR() makes use of a function scoped iterator\n'i', for several loops, and has a precedence of re-using the function\nscoped iterator declaration, but then proceeds to alias the iterator\nwith a new declaration in one of the later loops.\n\nRe-use the existing iterator variable for consistency, and to prevent\nvariable aliasing.\n\nSigned-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n---\n src/ipa/raspberrypi/controller/rpi/alsc.cpp | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)",
    "diff": "diff --git a/src/ipa/raspberrypi/controller/rpi/alsc.cpp b/src/ipa/raspberrypi/controller/rpi/alsc.cpp\nindex 42fbc8a476ad..8447f8bec18b 100644\n--- a/src/ipa/raspberrypi/controller/rpi/alsc.cpp\n+++ b/src/ipa/raspberrypi/controller/rpi/alsc.cpp\n@@ -628,7 +628,7 @@ static double gauss_seidel2_SOR(double const M[XY][4], double omega,\n \t\tlambda[i] = compute_lambda_bottom(i, M, lambda);\n \tlambda[0] = compute_lambda_bottom_start(0, M, lambda);\n \tdouble max_diff = 0;\n-\tfor (int i = 0; i < XY; i++) {\n+\tfor (i = 0; i < XY; i++) {\n \t\tlambda[i] = old_lambda[i] + (lambda[i] - old_lambda[i]) * omega;\n \t\tif (fabs(lambda[i] - old_lambda[i]) > fabs(max_diff))\n \t\t\tmax_diff = lambda[i] - old_lambda[i];\n",
    "prefixes": [
        "libcamera-devel",
        "08/10"
    ]
}