get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 812785,
    "url": "http://patchwork.ozlabs.org/api/patches/812785/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/lede/patch/20170912111250.31576-15-sojkam1@fel.cvut.cz/",
    "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": "<20170912111250.31576-15-sojkam1@fel.cvut.cz>",
    "list_archive_url": null,
    "date": "2017-09-12T11:12:44",
    "name": "[LEDE-DEV,procd,12/17] preload-seccomp: Use proper log level for error messages",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "8660239d6842ba937983f98024c1211136020cdc",
    "submitter": {
        "id": 14651,
        "url": "http://patchwork.ozlabs.org/api/people/14651/?format=api",
        "name": "Michal Sojka",
        "email": "sojkam1@fel.cvut.cz"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/lede/patch/20170912111250.31576-15-sojkam1@fel.cvut.cz/mbox/",
    "series": [
        {
            "id": 2665,
            "url": "http://patchwork.ozlabs.org/api/series/2665/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/lede/list/?series=2665",
            "date": "2017-09-12T11:12:36",
            "name": "[LEDE-DEV,procd,01/17] utrace: Fix environment initialization",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/2665/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/812785/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/812785/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",
        "Authentication-Results": [
            "ozlabs.org; spf=none (mailfrom)\n\tsmtp.mailfrom=lists.infradead.org (client-ip=65.50.211.133;\n\thelo=bombadil.infradead.org;\n\tenvelope-from=lede-dev-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org;\n\treceiver=<UNKNOWN>)",
            "ozlabs.org; dkim=pass (2048-bit key;\n\tunprotected) header.d=lists.infradead.org\n\theader.i=@lists.infradead.org header.b=\"JerkWAkB\"; \n\tdkim-atps=neutral"
        ],
        "Received": [
            "from bombadil.infradead.org (bombadil.infradead.org\n\t[65.50.211.133])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256\n\tbits)) (No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3xs2Mj2jzrz9s7g\n\tfor <incoming@patchwork.ozlabs.org>;\n\tTue, 12 Sep 2017 21:17:53 +1000 (AEST)",
            "from localhost ([127.0.0.1] helo=bombadil.infradead.org)\n\tby bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux))\n\tid 1drjCM-0000EC-6Q; Tue, 12 Sep 2017 11:17:46 +0000",
            "from smtpx.feld.cvut.cz ([147.32.192.33])\n\tby bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux))\n\tid 1drj8m-0004Yk-BU\n\tfor lede-dev@lists.infradead.org; Tue, 12 Sep 2017 11:14:12 +0000",
            "from localhost (unknown [192.168.200.7])\n\tby smtpx.feld.cvut.cz (Postfix) with ESMTP id 1C544DC3F6;\n\tTue, 12 Sep 2017 13:13:17 +0200 (CEST)",
            "from smtpx.feld.cvut.cz ([192.168.200.6])\n\tby localhost (styx.feld.cvut.cz [192.168.200.7]) (amavisd-new,\n\tport 10054)\n\twith ESMTP id dfBjpa7BuOir; Tue, 12 Sep 2017 13:13:15 +0200 (CEST)",
            "from imap.feld.cvut.cz (imap.feld.cvut.cz [147.32.192.34])\n\tby smtpx.feld.cvut.cz (Postfix) with ESMTP id 81887DC3EC;\n\tTue, 12 Sep 2017 13:13:13 +0200 (CEST)",
            "from wsh by steelpick.2x.cz with local (Exim 4.89)\n\t(envelope-from <sojkam1@fel.cvut.cz>)\n\tid 1drj7x-0008Eh-Cm; Tue, 12 Sep 2017 13:13:13 +0200"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;\n\td=lists.infradead.org; s=bombadil.20170209; h=Sender:\n\tContent-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe:\n\tList-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:Subject:References:\n\tIn-Reply-To:Message-Id:Date:To:From:Reply-To:Content-ID:Content-Description:\n\tResent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:\n\tList-Owner; bh=Uop5Hs5JbYmTQZLe0yaiDqxR++UI4lGHHlCuvNnUecc=;\n\tb=JerkWAkBg3x09m\n\tATURPSqhKUAONToi3gcODSuZIVhCnVYtPiOTP97L2F0wUiYBZv3JsPnQxakB1+aqlgF0UuKXoHtPs\n\tENGJvegyKrOXfich9hbsJQHaZhpvvH5p9rtKwA1sgJxmsyMT6AQNWC1SRpbzIblsPHg0Tso3SyDS0\n\tp5X3kXU/etCKQsDMeFU4Q4NjoFCJ85Sv8j2juJsS1hgGQG/JhCya0pPderf92ftyHXnWC6fv+tNzG\n\ttosTj3nqaJvSe4HFFSTm4PuFizRmJfdpdgGXboXzIKnd7AjBmUpuQPchuS6EjVUmhYanRhhpTIhKo\n\tSu7qqePECxj1BwCD5GEg==;",
        "X-Virus-Scanned": "IMAP STYX AMAVIS",
        "From": "Michal Sojka <sojkam1@fel.cvut.cz>",
        "To": "lede-dev@lists.infradead.org",
        "Date": "Tue, 12 Sep 2017 13:12:44 +0200",
        "Message-Id": "<20170912111250.31576-15-sojkam1@fel.cvut.cz>",
        "X-Mailer": "git-send-email 2.14.1",
        "In-Reply-To": "<20170912111250.31576-1-sojkam1@fel.cvut.cz>",
        "References": "<20170912111250.31576-1-sojkam1@fel.cvut.cz>",
        "X-CRM114-Version": "20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 ",
        "X-CRM114-CacheID": "sfid-20170912_041404_721281_232CD5F6 ",
        "X-CRM114-Status": "UNSURE (   7.26  )",
        "X-CRM114-Notice": "Please train this message.",
        "X-Spam-Score": "-4.2 (----)",
        "X-Spam-Report": "SpamAssassin version 3.4.1 on bombadil.infradead.org summary:\n\tContent analysis details:   (-4.2 points)\n\tpts rule name              description\n\t---- ----------------------\n\t--------------------------------------------------\n\t-2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/,\n\tmedium trust [147.32.192.33 listed in list.dnswl.org]\n\t-0.0 RP_MATCHES_RCVD Envelope sender domain matches handover relay\n\tdomain\n\t-1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%\n\t[score: 0.0000]",
        "Subject": "[LEDE-DEV] [PATCH procd 12/17] preload-seccomp: Use proper log\n\tlevel for error messages",
        "X-BeenThere": "lede-dev@lists.infradead.org",
        "X-Mailman-Version": "2.1.21",
        "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": "Michal Sojka <sojkam1@fel.cvut.cz>",
        "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": "Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>\n---\n jail/seccomp.c | 10 +++++-----\n jail/seccomp.h |  4 ++++\n 2 files changed, 9 insertions(+), 5 deletions(-)",
    "diff": "diff --git a/jail/seccomp.c b/jail/seccomp.c\nindex 1a2bb27..27bf3ce 100644\n--- a/jail/seccomp.c\n+++ b/jail/seccomp.c\n@@ -67,13 +67,13 @@ int install_syscall_filter(const char *argv, const char *file)\n \n \tblob_buf_init(&b, 0);\n \tif (!blobmsg_add_json_from_file(&b, file)) {\n-\t\tINFO(\"%s: failed to load %s\\n\", argv, file);\n+\t\tERROR(\"%s: failed to load %s\\n\", argv, file);\n \t\treturn -1;\n \t}\n \n \tblobmsg_parse(policy, __SECCOMP_MAX, tb, blob_data(b.head), blob_len(b.head));\n \tif (!tb[SECCOMP_WHITELIST]) {\n-\t\tINFO(\"%s: %s is missing the syscall table\\n\", argv, file);\n+\t\tERROR(\"%s: %s is missing the syscall table\\n\", argv, file);\n \t\treturn -1;\n \t}\n \n@@ -85,7 +85,7 @@ int install_syscall_filter(const char *argv, const char *file)\n \n \tfilter = calloc(sz, sizeof(struct sock_filter));\n \tif (!filter) {\n-\t\tINFO(\"failed to allocate filter memory\\n\");\n+\t\tERROR(\"failed to allocate filter memory\\n\");\n \t\treturn -1;\n \t}\n \n@@ -125,7 +125,7 @@ int install_syscall_filter(const char *argv, const char *file)\n \t\tset_filter(&filter[idx], BPF_RET + BPF_K, 0, 0, SECCOMP_RET_KILL);\n \n \tif (prctl(PR_SET_NO_NEW_PRIVS, 1, 0, 0, 0)) {\n-\t\tINFO(\"%s: prctl(PR_SET_NO_NEW_PRIVS) failed: %s\\n\", argv, strerror(errno));\n+\t\tERROR(\"%s: prctl(PR_SET_NO_NEW_PRIVS) failed: %s\\n\", argv, strerror(errno));\n \t\treturn errno;\n \t}\n \n@@ -133,7 +133,7 @@ int install_syscall_filter(const char *argv, const char *file)\n \tprog.filter = filter;\n \n \tif (prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, &prog)) {\n-\t\tINFO(\"%s: prctl(PR_SET_SECCOMP) failed: %s\\n\", argv, strerror(errno));\n+\t\tERROR(\"%s: prctl(PR_SET_SECCOMP) failed: %s\\n\", argv, strerror(errno));\n \t\treturn errno;\n \t}\n \treturn 0;\ndiff --git a/jail/seccomp.h b/jail/seccomp.h\nindex 6032812..24c1dd7 100644\n--- a/jail/seccomp.h\n+++ b/jail/seccomp.h\n@@ -20,6 +20,10 @@\n \tsyslog(LOG_INFO,\"preload-seccomp: \"fmt, ## __VA_ARGS__); \\\n \tfprintf(stderr,\"preload-seccomp: \"fmt, ## __VA_ARGS__); \\\n \t} while (0)\n+#define ERROR(fmt, ...) do { \\\n+\tsyslog(LOG_ERR,\"preload-seccomp: \"fmt, ## __VA_ARGS__); \\\n+\tfprintf(stderr,\"preload-seccomp: \"fmt, ## __VA_ARGS__); \\\n+\t} while (0)\n \n int install_syscall_filter(const char *argv, const char *file);\n \n",
    "prefixes": [
        "LEDE-DEV",
        "procd",
        "12/17"
    ]
}