Show a patch.

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

{
    "id": 16436,
    "url": "https://patchwork.libcamera.org/api/patches/16436/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/16436/",
    "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": "<20220629125551.330470-1-umang.jain@ideasonboard.com>",
    "date": "2022-06-29T12:55:51",
    "name": "[libcamera-devel] gstreamer: Be pedantic on srcpads access",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "dc2be480a9d285142af132057c3c6ea1cc7d5e64",
    "submitter": {
        "id": 86,
        "url": "https://patchwork.libcamera.org/api/people/86/?format=api",
        "name": "Umang Jain",
        "email": "umang.jain@ideasonboard.com"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/16436/mbox/",
    "series": [
        {
            "id": 3233,
            "url": "https://patchwork.libcamera.org/api/series/3233/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=3233",
            "date": "2022-06-29T12:55:51",
            "name": "[libcamera-devel] gstreamer: Be pedantic on srcpads access",
            "version": 1,
            "mbox": "https://patchwork.libcamera.org/series/3233/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/16436/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/16436/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 60C90BE173\n\tfor <parsemail@patchwork.libcamera.org>;\n\tWed, 29 Jun 2022 12:56:06 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id A094965635;\n\tWed, 29 Jun 2022 14:56:05 +0200 (CEST)",
            "from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id C0F0960412\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 29 Jun 2022 14:56:03 +0200 (CEST)",
            "from perceval.ideasonboard.com (unknown\n\t[IPv6:2401:4900:1f3f:ca21:e286:106b:5da4:9482])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 548AA3D7;\n\tWed, 29 Jun 2022 14:56:01 +0200 (CEST)"
        ],
        "DKIM-Signature": [
            "v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1656507365;\n\tbh=uUeEM+bTmfxHMOC2BDRIKGb7c1yaykikzoEXy8vxFOI=;\n\th=To:Date:Subject:List-Id:List-Unsubscribe:List-Archive:List-Post:\n\tList-Help:List-Subscribe:From:Reply-To:Cc:From;\n\tb=Z5YxocV3ODG4mr1lD8vvIa3Mz+UMU2pPOh8DB1ODbUtbdrW5zvopl/TWoIecb6blx\n\t4v1vgS75uVKXM4oNCVRroVmD2yYE41myPaJg7ey9Duf92xRDUFW2bzQszYcU5/CN2y\n\t2e5JVXNqt3MtimMQPqmh6XQMBC5t2pepUHuijjN2B4ZPBH/gO+H/7qHVRMZ6hBIVZr\n\t7h39/NBH+4MkhcrHC7ygg5Ib6o98f0WE+LnVOcn1al6X2jXyMQ4sRJePwhxnGFSpiZ\n\tO2ZNljASVpJCFCpRavXX+Wr0Quj/nMS+PMU6ZSmjdO8kLzK8RntAHslq6bcSWk3vZV\n\tOIGLmwHYOVruA==",
            "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1656507363;\n\tbh=uUeEM+bTmfxHMOC2BDRIKGb7c1yaykikzoEXy8vxFOI=;\n\th=From:To:Cc:Subject:Date:From;\n\tb=SgC+8j2PMmMV9bhOLfR3xG7rkk3nCVH2x1uaU1KNL13a+9+vie43OWxpwGC+mSw/D\n\teCEyE5rWcT+R2d7I20/jdh5+6d6z9IqWLEeTuOM4YrIOWq/+sPKBIf9sWCXQPdBdx4\n\t5LJn8FTHEX64AQWFgw5F/tODK/70L8vNLXB2BL2s="
        ],
        "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"SgC+8j2P\"; dkim-atps=neutral",
        "To": "libcamera-devel@lists.libcamera.org",
        "Date": "Wed, 29 Jun 2022 18:25:51 +0530",
        "Message-Id": "<20220629125551.330470-1-umang.jain@ideasonboard.com>",
        "X-Mailer": "git-send-email 2.31.1",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[libcamera-devel] [PATCH] gstreamer: Be pedantic on srcpads access",
        "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>",
        "From": "Umang Jain via libcamera-devel <libcamera-devel@lists.libcamera.org>",
        "Reply-To": "Umang Jain <umang.jain@ideasonboard.com>",
        "Cc": "nicolas.dufresne@collabora.com, vedantparanjape160201@gmail.com",
        "Errors-To": "libcamera-devel-bounces@lists.libcamera.org",
        "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"
    },
    "content": "While the \"src\" pad is added to the element, it is accessed\nvia a index number. If multiple pads are added(in future)\nand tracked in state->srcpads_, the index might need re-adjusting.\n\nUse the std::vector::back() instead of index, which corresponds\nto std::vector::push_back() for tracking of pads. It also slightly\nhelps with readability.\n\nNo functional changes intended.\n\nSigned-off-by: Umang Jain <umang.jain@ideasonboard.com>\n---\n src/gstreamer/gstlibcamerasrc.cpp | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)",
    "diff": "diff --git a/src/gstreamer/gstlibcamerasrc.cpp b/src/gstreamer/gstlibcamerasrc.cpp\nindex 46fd02d2..4813ab96 100644\n--- a/src/gstreamer/gstlibcamerasrc.cpp\n+++ b/src/gstreamer/gstlibcamerasrc.cpp\n@@ -631,7 +631,7 @@ gst_libcamera_src_init(GstLibcameraSrc *self)\n \tgst_task_set_lock(self->task, &self->stream_lock);\n \n \tstate->srcpads_.push_back(gst_pad_new_from_template(templ, \"src\"));\n-\tgst_element_add_pad(GST_ELEMENT(self), state->srcpads_[0]);\n+\tgst_element_add_pad(GST_ELEMENT(self), state->srcpads_.back());\n \n \t/* C-style friend. */\n \tstate->src_ = self;\n",
    "prefixes": [
        "libcamera-devel"
    ]
}