Show a patch.

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

{
    "id": 1018,
    "url": "https://patchwork.libcamera.org/api/patches/1018/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/1018/",
    "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": "<20190416220839.1577-10-laurent.pinchart@ideasonboard.com>",
    "date": "2019-04-16T22:08:35",
    "name": "[libcamera-devel,v2,09/13] libcamera: v4l2_subdevice: Close subdevice when destroyed",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "06ee80843c00ae32cf3a9a746cd3811756b0484b",
    "submitter": {
        "id": 2,
        "url": "https://patchwork.libcamera.org/api/people/2/?format=api",
        "name": "Laurent Pinchart",
        "email": "laurent.pinchart@ideasonboard.com"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/1018/mbox/",
    "series": [
        {
            "id": 253,
            "url": "https://patchwork.libcamera.org/api/series/253/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=253",
            "date": "2019-04-16T22:08:26",
            "name": "Rockchip ISP pipeline handler",
            "version": 2,
            "mbox": "https://patchwork.libcamera.org/series/253/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/1018/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/1018/checks/",
    "tags": {},
    "headers": {
        "Return-Path": "<laurent.pinchart@ideasonboard.com>",
        "Received": [
            "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 6D86360DCC\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 17 Apr 2019 00:08:54 +0200 (CEST)",
            "from pendragon.bb.dnainternet.fi\n\t(dfj612yhrgyx302h3jwwy-3.rev.dnainternet.fi\n\t[IPv6:2001:14ba:21f5:5b00:ce28:277f:58d7:3ca4])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 1347BE2\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 17 Apr 2019 00:08:54 +0200 (CEST)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1555452534;\n\tbh=a5p2WN0SdnqNVGvtj5mUdm1cWRoe34iGSLYcw0Rw86A=;\n\th=From:To:Subject:Date:In-Reply-To:References:From;\n\tb=rOuHG4CRB6qsN4N574shsp7RIVUbu+WN1qev+EdJ7eteJLV+8ZinMkZCIJGoZoSr3\n\tHYrqr4PvOLlV87OoOr+e1ezZbAYEk1369Xz/68JSUHkv8qFbFOGdaQvQRFPTW7wo6x\n\tHBV6OlyLzm/y2Opjrofk2AtkyY52pTuv3Bjecw8I=",
        "From": "Laurent Pinchart <laurent.pinchart@ideasonboard.com>",
        "To": "libcamera-devel@lists.libcamera.org",
        "Date": "Wed, 17 Apr 2019 01:08:35 +0300",
        "Message-Id": "<20190416220839.1577-10-laurent.pinchart@ideasonboard.com>",
        "X-Mailer": "git-send-email 2.21.0",
        "In-Reply-To": "<20190416220839.1577-1-laurent.pinchart@ideasonboard.com>",
        "References": "<20190416220839.1577-1-laurent.pinchart@ideasonboard.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[libcamera-devel] [PATCH v2 09/13] libcamera: v4l2_subdevice: Close\n\tsubdevice when destroyed",
        "X-BeenThere": "libcamera-devel@lists.libcamera.org",
        "X-Mailman-Version": "2.1.23",
        "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>",
        "X-List-Received-Date": "Tue, 16 Apr 2019 22:08:55 -0000"
    },
    "content": "Make sure the subdevice file descriptor isn't leaked by closing it when\nthe V4L2Subdevice instance is destroyed.\n\nSigned-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n---\n src/libcamera/include/v4l2_subdevice.h | 1 +\n src/libcamera/v4l2_subdevice.cpp       | 5 +++++\n 2 files changed, 6 insertions(+)",
    "diff": "diff --git a/src/libcamera/include/v4l2_subdevice.h b/src/libcamera/include/v4l2_subdevice.h\nindex c71dce7d8644..e592d67dd043 100644\n--- a/src/libcamera/include/v4l2_subdevice.h\n+++ b/src/libcamera/include/v4l2_subdevice.h\n@@ -35,6 +35,7 @@ public:\n \texplicit V4L2Subdevice(const MediaEntity *entity);\n \tV4L2Subdevice(const V4L2Subdevice &) = delete;\n \tV4L2Subdevice &operator=(const V4L2Subdevice &) = delete;\n+\t~V4L2Subdevice();\n \n \tint open();\n \tbool isOpen() const;\ndiff --git a/src/libcamera/v4l2_subdevice.cpp b/src/libcamera/v4l2_subdevice.cpp\nindex e34cc1693b46..a03fadfd579e 100644\n--- a/src/libcamera/v4l2_subdevice.cpp\n+++ b/src/libcamera/v4l2_subdevice.cpp\n@@ -112,6 +112,11 @@ V4L2Subdevice::V4L2Subdevice(const MediaEntity *entity)\n {\n }\n \n+V4L2Subdevice::~V4L2Subdevice()\n+{\n+\tclose();\n+}\n+\n /**\n  * \\brief Open a V4L2 subdevice\n  *\n",
    "prefixes": [
        "libcamera-devel",
        "v2",
        "09/13"
    ]
}