Show a patch.

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

{
    "id": 3459,
    "url": "https://patchwork.libcamera.org/api/patches/3459/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/3459/",
    "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": "<20200414070642.22366-4-email@uajain.com>",
    "date": "2020-04-14T07:06:59",
    "name": "[libcamera-devel,3/3] test: v4l2_videodevice: buffer_cache: Fail the test if no buffer from cache is obtained",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "c8c06740b2d3cdb7c67fe59f4206d6e37b92d3d2",
    "submitter": {
        "id": 1,
        "url": "https://patchwork.libcamera.org/api/people/1/?format=api",
        "name": "Umang Jain",
        "email": "email@uajain.com"
    },
    "delegate": {
        "id": 12,
        "url": "https://patchwork.libcamera.org/api/users/12/?format=api",
        "username": "uajain",
        "first_name": "Umang",
        "last_name": "Jain",
        "email": "umang.jain@ideasonboard.com"
    },
    "mbox": "https://patchwork.libcamera.org/patch/3459/mbox/",
    "series": [
        {
            "id": 807,
            "url": "https://patchwork.libcamera.org/api/series/807/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=807",
            "date": "2020-04-14T07:06:52",
            "name": "More Coverity scans fixes",
            "version": 1,
            "mbox": "https://patchwork.libcamera.org/series/807/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/3459/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/3459/checks/",
    "tags": {},
    "headers": {
        "Return-Path": "<bounces+15657259-5c31-libcamera-devel=lists.libcamera.org@em7280.uajain.com>",
        "Received": [
            "from o1.f.az.sendgrid.net (o1.f.az.sendgrid.net [208.117.55.132])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id A7E8362E41\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 14 Apr 2020 09:07:00 +0200 (CEST)",
            "by filter0081p3las1.sendgrid.net with SMTP id\n\tfilter0081p3las1-23682-5E956112-11D\n\t2020-04-14 07:06:59.17861901 +0000 UTC m=+1071360.368382965",
            "from mail.uajain.com (unknown)\n\tby ismtpd0005p1maa1.sendgrid.net (SG) with ESMTP\n\tid ILp-WIe8Q3W3Y1zovR9l5w Tue, 14 Apr 2020 07:06:58.670 +0000 (UTC)"
        ],
        "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=uajain.com\n\theader.i=@uajain.com header.b=\"XN2YPgeS\"; \n\tdkim-atps=neutral",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=uajain.com;\n\th=from:subject:in-reply-to:references:mime-version:to:cc:\n\tcontent-transfer-encoding:content-type;\n\ts=s1; bh=ciyi7nLIPvT9ePashq6eXudVkrTZwv2SOMfzMQAOSgs=;\n\tb=XN2YPgeSV88mDGOPTHoOnBW22wZ/w2IPDdD4VH+fylFG8d9NWVaDjeJL6klvWc2HLUeB\n\tJtsJ7RNsXFpAPXMKzbTnRBfYTr22gJiBzM8C5uR8N/EGmIWPeWuy2WmdG7hJL3mZstnYnE\n\tID6wpY9J9bbv4wVq53TizoZZZvB+Tl+1o=",
        "From": "Umang Jain <email@uajain.com>",
        "Date": "Tue, 14 Apr 2020 07:06:59 +0000 (UTC)",
        "Message-Id": "<20200414070642.22366-4-email@uajain.com>",
        "In-Reply-To": "<20200414070642.22366-1-email@uajain.com>",
        "References": "<20200414070642.22366-1-email@uajain.com>",
        "Mime-Version": "1.0",
        "X-SG-EID": "1Q40EQ7YGir8a9gjSIAdTjhngY657NMk9ckeo4dbHZDiOpywc/L3L9rFqlwE4KPc8Y1sFjEEckHl5AFRmKDueuFuam3Ti9xR18CbViEtKZIG6JOaQQXh4HDflpOF0cviKfs19XJXwE5xmjAb0wuStb5hkUBFmPGJ8v2ACSrJ2ms1kDdGNHoQ0MXQn7npCNNJ4VTOLpRUl5FoaeCv0T2XX12+BiyJX8BH/EAgE6hKH0WeCnnQmHAKctlQSyqDr6/J",
        "To": "libcamera-devel@lists.libcamera.org",
        "Content-Transfer-Encoding": "7bit",
        "Content-Type": "text/plain; charset=us-ascii",
        "Subject": "[libcamera-devel] [PATCH 3/3] test: v4l2_videodevice: buffer_cache:\n\tFail the test if no buffer from cache is obtained",
        "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>",
        "X-List-Received-Date": "Tue, 14 Apr 2020 07:07:01 -0000"
    },
    "content": "Failing the test guards against negative index (-ENOENT in this case)\nbeing passed to V4L2BufferCache::put().\n\nPointed out by Coverity DefectId=279090\n\nSigned-off-by: Umang Jain <email@uajain.com>\n---\n test/v4l2_videodevice/buffer_cache.cpp | 5 +++++\n 1 file changed, 5 insertions(+)",
    "diff": "diff --git a/test/v4l2_videodevice/buffer_cache.cpp b/test/v4l2_videodevice/buffer_cache.cpp\nindex d730e75..1870249 100644\n--- a/test/v4l2_videodevice/buffer_cache.cpp\n+++ b/test/v4l2_videodevice/buffer_cache.cpp\n@@ -90,6 +90,11 @@ public:\n \t\t/* Pick a hot buffer at random and store its index. */\n \t\tint hotBuffer = dist(generator_);\n \t\tint hotIndex = cache->get(*buffers[hotBuffer].get());\n+\t\tif (hotIndex < 0) {\n+\t\t\tstd::cout << \"Failed lookup from cache\" << std::endl;\n+\t\t\treturn TestFail;\n+\t\t}\n+\n \t\tcache->put(hotIndex);\n \n \t\t/*\n",
    "prefixes": [
        "libcamera-devel",
        "3/3"
    ]
}