get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 627554,
    "url": "http://patchwork.ozlabs.org/api/patches/627554/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/lede/patch/1464565158-18043-1-git-send-email-champetier.etienne@gmail.com/",
    "project": {
        "id": 54,
        "url": "http://patchwork.ozlabs.org/api/projects/54/?format=api",
        "name": "LEDE development",
        "link_name": "lede",
        "list_id": "lede-dev.lists.infradead.org",
        "list_email": "lede-dev@lists.infradead.org",
        "web_url": "http://lede-project.org/",
        "scm_url": "",
        "webscm_url": "http://git.lede-project.org/",
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<1464565158-18043-1-git-send-email-champetier.etienne@gmail.com>",
    "list_archive_url": null,
    "date": "2016-05-29T23:39:12",
    "name": "[LEDE-DEV,procd,1/7] jail: call chdir(/) after pivot_root()",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "a4dd741f5e24ecf69b3e5c021aafed29f51ae669",
    "submitter": {
        "id": 65689,
        "url": "http://patchwork.ozlabs.org/api/people/65689/?format=api",
        "name": "Etienne Champetier",
        "email": "champetier.etienne@gmail.com"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/lede/patch/1464565158-18043-1-git-send-email-champetier.etienne@gmail.com/mbox/",
    "series": [],
    "comments": "http://patchwork.ozlabs.org/api/patches/627554/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/627554/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<lede-dev-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org>",
        "X-Original-To": "incoming@patchwork.ozlabs.org",
        "Delivered-To": "patchwork-incoming@bilbo.ozlabs.org",
        "Received": [
            "from bombadil.infradead.org (bombadil.infradead.org\n\t[IPv6:2001:1868:205::9])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128\n\tbits)) (No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3rHx9X3WB4z9t3q\n\tfor <incoming@patchwork.ozlabs.org>;\n\tMon, 30 May 2016 09:41:52 +1000 (AEST)",
            "from localhost ([127.0.0.1] helo=bombadil.infradead.org)\n\tby bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux))\n\tid 1b7AJF-0007zc-10; Sun, 29 May 2016 23:39:53 +0000",
            "from mail-wm0-x243.google.com ([2a00:1450:400c:c09::243])\n\tby bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat\n\tLinux)) id 1b7AJA-0007w5-9n\n\tfor lede-dev@lists.infradead.org; Sun, 29 May 2016 23:39:49 +0000",
            "by mail-wm0-x243.google.com with SMTP id n129so17523642wmn.1\n\tfor <lede-dev@lists.infradead.org>;\n\tSun, 29 May 2016 16:39:27 -0700 (PDT)",
            "from ubuntu1404.lxcnattst (ns623510.ovh.net. [5.135.134.9])\n\tby smtp.gmail.com with ESMTPSA id\n\t124sm20721292wml.12.2016.05.29.16.39.25\n\t(version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128);\n\tSun, 29 May 2016 16:39:25 -0700 (PDT)"
        ],
        "Authentication-Results": "ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=gmail.com header.i=@gmail.com header.b=rkI3zuMZ;\n\tdkim-atps=neutral",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;\n\th=from:to:cc:subject:date:message-id;\n\tbh=u/3dksZDD1fSTK7TCcJMje9Oj7nPF83KRIz9k97PWQA=;\n\tb=rkI3zuMZcIfszSwLWgexS+ADVWCWKO62OVwa/EplAQPdkUdu32tqCaJuz31fR+A/Wh\n\tbLW7vw9q2om2InRnG2dV686/btu2bc4bq5saU4WL2XSJBKok8WpNiMIXFph4veUwbH6n\n\taioTZnQLsNoJ44V3bGX+F1RPH/pkX8REME3lTuAi09s+emv272qXisp/osw36vnc16KP\n\toX6crU1QjA4TB8NSWukQo69whf1MSLg6kXcmVv/Xs4gyMWqHWTKytKkfsJwkHQc9ye1Z\n\tUaY+9GaINE9PFP5k5ZR47BDOcWrggyr8eUsgD5OQ4IupeUlALS0f5pp8/I5kGflDjH6C\n\tYiCg==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20130820;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id;\n\tbh=u/3dksZDD1fSTK7TCcJMje9Oj7nPF83KRIz9k97PWQA=;\n\tb=ZcDlE6e8q0SqOlQxuH4cxL+uBhiAGihWvUHXvmYYpews/oya/NvE3qf9XrFYbI9pAQ\n\tgfwX8TY+sD8Ow8Z1CDV/jgNMzzRDbDSmFKADui6UnFgyb7Jt7b7uIqJQA5AhTmUUzv+p\n\tJDzV4jMwNCo0xI+6DRQh3VmRxXkGDzkBGUPQSc8oy6KHpZ1BJvhLrkIG4knrn4+DtyVj\n\tB8gha2mwgiOnMjbQcncQMTmvFJwJPlj1Wb8XjdpjxKli3vfAMrEqt+otSzudvy5+9CvT\n\t9xgDfS9T0xrVBeTDS0qz4h9dxsfcelFxykWH+5bmEMVDAWCEXKfBUKYz5MnMZLfrhvnf\n\tkQdA==",
        "X-Gm-Message-State": "ALyK8tIcSlMjs3X6PU2gk66hSdfI+BAlxPjQIBF2aKH8/B+sWlhPLgIcrTYHSzp0XUvBwg==",
        "X-Received": "by 10.28.137.14 with SMTP id l14mr7647039wmd.64.1464565165797;\n\tSun, 29 May 2016 16:39:25 -0700 (PDT)",
        "From": "Etienne CHAMPETIER <champetier.etienne@gmail.com>",
        "To": "lede-dev@lists.infradead.org",
        "Date": "Sun, 29 May 2016 23:39:12 +0000",
        "Message-Id": "<1464565158-18043-1-git-send-email-champetier.etienne@gmail.com>",
        "X-Mailer": "git-send-email 1.9.1",
        "X-CRM114-Version": "20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 ",
        "X-CRM114-CacheID": "sfid-20160529_163948_556318_695DE43D ",
        "X-CRM114-Status": "UNSURE (   8.15  )",
        "X-CRM114-Notice": "Please train this message.",
        "X-Spam-Score": "-2.7 (--)",
        "X-Spam-Report": "SpamAssassin version 3.4.0 on bombadil.infradead.org summary:\n\tContent analysis details:   (-2.7 points)\n\tpts rule name              description\n\t---- ----------------------\n\t--------------------------------------------------\n\t-0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/,\n\tlow\n\ttrust [2a00:1450:400c:c09:0:0:0:243 listed in] [list.dnswl.org]\n\t-0.0 SPF_PASS               SPF: sender matches SPF record\n\t0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail\n\tprovider (champetier.etienne[at]gmail.com)\n\t-1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%\n\t[score: 0.0000]\n\t-0.1 DKIM_VALID Message has at least one valid DKIM or DK signature\n\t-0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from\n\tauthor's domain\n\t0.1 DKIM_SIGNED            Message has a DKIM or DK signature,\n\tnot necessarily valid",
        "Subject": "[LEDE-DEV] [PATCH procd 1/7] jail: call chdir(/) after pivot_root()",
        "X-BeenThere": "lede-dev@lists.infradead.org",
        "X-Mailman-Version": "2.1.20",
        "Precedence": "list",
        "List-Id": "<lede-dev.lists.infradead.org>",
        "List-Unsubscribe": "<http://lists.infradead.org/mailman/options/lede-dev>,\n\t<mailto:lede-dev-request@lists.infradead.org?subject=unsubscribe>",
        "List-Archive": "<http://lists.infradead.org/pipermail/lede-dev/>",
        "List-Post": "<mailto:lede-dev@lists.infradead.org>",
        "List-Help": "<mailto:lede-dev-request@lists.infradead.org?subject=help>",
        "List-Subscribe": "<http://lists.infradead.org/mailman/listinfo/lede-dev>,\n\t<mailto:lede-dev-request@lists.infradead.org?subject=subscribe>",
        "Cc": "Etienne CHAMPETIER <champetier.etienne@gmail.com>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=\"us-ascii\"",
        "Content-Transfer-Encoding": "7bit",
        "Sender": "\"Lede-dev\" <lede-dev-bounces@lists.infradead.org>",
        "Errors-To": "lede-dev-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org"
    },
    "content": "pivot_root(2) man page recommend calling chdir(/), so do it\n\nSigned-off-by: Etienne CHAMPETIER <champetier.etienne@gmail.com>\n---\n jail/jail.c | 4 ++++\n 1 file changed, 4 insertions(+)",
    "diff": "diff --git a/jail/jail.c b/jail/jail.c\nindex 541363a..8157a8f 100644\n--- a/jail/jail.c\n+++ b/jail/jail.c\n@@ -162,6 +162,10 @@ static int build_jail_fs(void)\n \t\tERROR(\"pivot_root failed: %s\\n\", strerror(errno));\n \t\treturn -1;\n \t}\n+\tif (chdir(\"/\")) {\n+\t\tERROR(\"chdir(/) failed: %s\\n\", strerror(errno));\n+\t\treturn -1;\n+\t}\n \n \tsnprintf(dirbuf, sizeof(dirbuf), \"/old%s\", jail_root);\n \trmdir(dirbuf);\n",
    "prefixes": [
        "LEDE-DEV",
        "procd",
        "1/7"
    ]
}