get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 2217543,
    "url": "http://patchwork.ozlabs.org/api/patches/2217543/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/linux-um/patch/20260330062921.40824-1-pengpeng@iscas.ac.cn/",
    "project": {
        "id": 60,
        "url": "http://patchwork.ozlabs.org/api/projects/60/?format=api",
        "name": "User-mode Linux Development",
        "link_name": "linux-um",
        "list_id": "linux-um.lists.infradead.org",
        "list_email": "linux-um@lists.infradead.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": "",
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20260330062921.40824-1-pengpeng@iscas.ac.cn>",
    "list_archive_url": null,
    "date": "2026-03-30T06:29:21",
    "name": "[4/4] um: account for the separator in add_arg() bounds checking",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "c6f5454ca178032af9cfd207392768f44ea442b3",
    "submitter": {
        "id": 93000,
        "url": "http://patchwork.ozlabs.org/api/people/93000/?format=api",
        "name": "Pengpeng Hou",
        "email": "pengpeng@iscas.ac.cn"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/linux-um/patch/20260330062921.40824-1-pengpeng@iscas.ac.cn/mbox/",
    "series": [
        {
            "id": 497961,
            "url": "http://patchwork.ozlabs.org/api/series/497961/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/linux-um/list/?series=497961",
            "date": "2026-03-30T06:29:21",
            "name": null,
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/497961/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/2217543/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/2217543/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "\n <linux-um-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org>",
        "X-Original-To": "incoming@patchwork.ozlabs.org",
        "Delivered-To": "patchwork-incoming@legolas.ozlabs.org",
        "Authentication-Results": [
            "legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n secure) header.d=lists.infradead.org header.i=@lists.infradead.org\n header.a=rsa-sha256 header.s=bombadil.20210309 header.b=1Iw9RCf5;\n\tdkim-atps=neutral",
            "legolas.ozlabs.org;\n spf=none (no SPF record) smtp.mailfrom=lists.infradead.org\n (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org;\n envelope-from=linux-um-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org;\n receiver=patchwork.ozlabs.org)"
        ],
        "Received": [
            "from bombadil.infradead.org (bombadil.infradead.org\n [IPv6:2607:7c80:54:3::133])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fkhDn5L1Jz1xrn\n\tfor <incoming@patchwork.ozlabs.org>; Mon, 30 Mar 2026 17:29:37 +1100 (AEDT)",
            "from localhost ([::1] helo=bombadil.infradead.org)\n\tby bombadil.infradead.org with esmtp (Exim 4.98.2 #2 (Red Hat Linux))\n\tid 1w767x-0000000Agqj-2j79;\n\tMon, 30 Mar 2026 06:29:33 +0000",
            "from smtp25.cstnet.cn ([159.226.251.25] helo=cstnet.cn)\n\tby bombadil.infradead.org with esmtps (Exim 4.98.2 #2 (Red Hat Linux))\n\tid 1w767u-0000000Agps-14EM\n\tfor linux-um@lists.infradead.org;\n\tMon, 30 Mar 2026 06:29:32 +0000",
            "from localhost.localdomain (unknown [111.196.245.197])\n\tby APP-05 (Coremail) with SMTP id zQCowAC3Sw9BGMppOoTpCw--.28728S2;\n\tMon, 30 Mar 2026 14:29:21 +0800 (CST)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;\n\td=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help\n\t:List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding:\n\tMIME-Version:Message-ID:Date:Subject:Cc:To:From:Reply-To:Content-Type:\n\tContent-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:\n\tResent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner;\n\tbh=xv6/ZeDGYexoa/mwjc+SiZM70Leb/BKjtuZKejAsOyQ=; b=1Iw9RCf5p/dApNm5pjTeRXR48K\n\tTljMl0DwGxPsTeVFOVtoZmw8aBKMYZ+IIfQsRJBOMewVvVVxe6B6TxYpFly/EJ3f7g005EH2FpZym\n\tRKHYxTbp4Fmd/n+DMmFTV7AkcaxCMIXe3aC+HOblZGGLSawZgeWXDDnW+wmcyQ09vxDalfhRiZjdo\n\tmXMEVvRbKErX/oCxLiU7QfKEAQIkYKFTqFrF79qs9v51HdoWI9zIk3xnW1F6FwAo1BZJyPHqfeZrW\n\tldLbYwAJ2c2MFijNm0TVmxrKjosT4rnFF83udSNIdusotUMo0jPx4OmS0QnWTcA08GHd8XdWPZkDM\n\tRyxfkBDg==;",
        "From": "Pengpeng Hou <pengpeng@iscas.ac.cn>",
        "To": "richard@nod.at",
        "Cc": "anton.ivanov@cambridgegreys.com,\n\tjohannes@sipsolutions.net,\n\tlinux-um@lists.infradead.org,\n\tlinux-kernel@vger.kernel.org,\n\tpengpeng@iscas.ac.cn",
        "Subject": "[PATCH 4/4] um: account for the separator in add_arg() bounds\n checking",
        "Date": "Mon, 30 Mar 2026 14:29:21 +0800",
        "Message-ID": "<20260330062921.40824-1-pengpeng@iscas.ac.cn>",
        "X-Mailer": "git-send-email 2.50.1",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "X-CM-TRANSID": "zQCowAC3Sw9BGMppOoTpCw--.28728S2",
        "X-Coremail-Antispam": "1UD129KBjvdXoW7JF47Z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"X-Originating-IP": "[111.196.245.197]",
        "X-CM-SenderInfo": "pshqw1xhqjqxpvfd2hldfou0/",
        "X-CRM114-Version": "20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 ",
        "X-CRM114-CacheID": "sfid-20260329_232930_666889_CFCC8B18 ",
        "X-CRM114-Status": "GOOD (  10.46  )",
        "X-Spam-Score": "1.1 (+)",
        "X-Spam-Report": "Spam detection software,\n running on the system \"bombadil.infradead.org\",\n has NOT identified this incoming email as spam.  The original\n message has been attached to this so you can view it or label\n similar future email.  If you have any questions, see\n the administrator of that system for details.\n Content preview:  add_arg() checks whether command_line and arg fit in the\n fixed\n    COMMAND_LINE_SIZE buffer, but when command_line is non-empty it inserts an\n    additional space before appending arg. The current guard does [...]\n Content analysis details:   (1.1 points, 5.0 required)\n  pts rule name              description\n ---- ----------------------\n --------------------------------------------------\n -0.0 RCVD_IN_DNSWL_NONE     RBL: Sender listed at https://www.dnswl.org/, no\n                             trust\n                             [159.226.251.25 listed in list.dnswl.org]\n  1.0 RCVD_IN_VALIDITY_CERTIFIED_BLOCKED RBL: ADMINISTRATOR NOTICE: The\n                             query to Validity was blocked.  See\n                             https://knowledge.validity.com/hc/en-us/articles/20961730681243\n                              for more information.\n                         [159.226.251.25 listed in\n sa-trusted.bondedsender.org]\n  1.0 RCVD_IN_VALIDITY_SAFE_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to\n                              Validity was blocked.  See\n                             https://knowledge.validity.com/hc/en-us/articles/20961730681243\n                              for more information.\n                             [159.226.251.25 listed in sa-accredit.habeas.com]\n  1.0 RCVD_IN_VALIDITY_RPBL_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to\n                              Validity was blocked.  See\n                             https://knowledge.validity.com/hc/en-us/articles/20961730681243\n                              for more information.\n                            [159.226.251.25 listed in\n bl.score.senderscore.com]\n -0.0 SPF_HELO_PASS          SPF: HELO matches SPF record\n -0.0 SPF_PASS               SPF: sender matches SPF record\n -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%\n                             [score: 0.0000]",
        "X-BeenThere": "linux-um@lists.infradead.org",
        "X-Mailman-Version": "2.1.34",
        "Precedence": "list",
        "List-Id": "<linux-um.lists.infradead.org>",
        "List-Unsubscribe": "<http://lists.infradead.org/mailman/options/linux-um>,\n <mailto:linux-um-request@lists.infradead.org?subject=unsubscribe>",
        "List-Archive": "<http://lists.infradead.org/pipermail/linux-um/>",
        "List-Post": "<mailto:linux-um@lists.infradead.org>",
        "List-Help": "<mailto:linux-um-request@lists.infradead.org?subject=help>",
        "List-Subscribe": "<http://lists.infradead.org/mailman/listinfo/linux-um>,\n <mailto:linux-um-request@lists.infradead.org?subject=subscribe>",
        "Sender": "\"linux-um\" <linux-um-bounces@lists.infradead.org>",
        "Errors-To": "linux-um-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org"
    },
    "content": "add_arg() checks whether command_line and arg fit in the fixed\nCOMMAND_LINE_SIZE buffer, but when command_line is non-empty it inserts\nan additional space before appending arg. The current guard does not\naccount for that separator, so a non-empty command line can pass the\ncheck and still overflow by one byte.\n\nCount the separator when command_line already contains data.\n\nSigned-off-by: Pengpeng Hou <pengpeng@iscas.ac.cn>\n---\n arch/um/kernel/um_arch.c | 7 ++++++-\n 1 file changed, 6 insertions(+), 1 deletion(-)",
    "diff": "diff --git a/arch/um/kernel/um_arch.c b/arch/um/kernel/um_arch.c\nindex e2b24e1ecfa6..93eebaf1d236 100644\n--- a/arch/um/kernel/um_arch.c\n+++ b/arch/um/kernel/um_arch.c\n@@ -44,7 +44,12 @@ static char __initdata command_line[COMMAND_LINE_SIZE] = { 0 };\n \n static void __init add_arg(char *arg)\n {\n-\tif (strlen(command_line) + strlen(arg) + 1 > COMMAND_LINE_SIZE) {\n+\tsize_t len = strlen(command_line) + strlen(arg) + 1;\n+\n+\tif (command_line[0])\n+\t\tlen++;\n+\n+\tif (len > COMMAND_LINE_SIZE) {\n \t\tos_warn(\"add_arg: Too many command line arguments!\\n\");\n \t\texit(1);\n \t}\n",
    "prefixes": [
        "4/4"
    ]
}