get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 808884,
    "url": "http://patchwork.ozlabs.org/api/patches/808884/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/glibc/patch/20170901180029.9527-25-hjl.tools@gmail.com/",
    "project": {
        "id": 41,
        "url": "http://patchwork.ozlabs.org/api/projects/41/?format=api",
        "name": "GNU C Library",
        "link_name": "glibc",
        "list_id": "libc-alpha.sourceware.org",
        "list_email": "libc-alpha@sourceware.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": "",
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20170901180029.9527-25-hjl.tools@gmail.com>",
    "list_archive_url": null,
    "date": "2017-09-01T17:59:55",
    "name": "[24/58] Hide __chmod and __mkdir [BZ #18822]",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "41772edaf378ea799dee0bf0aeb21a71febd4ac8",
    "submitter": {
        "id": 4387,
        "url": "http://patchwork.ozlabs.org/api/people/4387/?format=api",
        "name": "H.J. Lu",
        "email": "hjl.tools@gmail.com"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/glibc/patch/20170901180029.9527-25-hjl.tools@gmail.com/mbox/",
    "series": [
        {
            "id": 1088,
            "url": "http://patchwork.ozlabs.org/api/series/1088/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/glibc/list/?series=1088",
            "date": "2017-09-01T18:00:21",
            "name": "Hide internal functions in libc.so",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/1088/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/808884/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/808884/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<libc-alpha-return-84077-incoming=patchwork.ozlabs.org@sourceware.org>",
        "X-Original-To": "incoming@patchwork.ozlabs.org",
        "Delivered-To": [
            "patchwork-incoming@bilbo.ozlabs.org",
            "mailing list libc-alpha@sourceware.org"
        ],
        "Authentication-Results": [
            "ozlabs.org;\n\tspf=pass (mailfrom) smtp.mailfrom=sourceware.org\n\t(client-ip=209.132.180.131; helo=sourceware.org;\n\tenvelope-from=libc-alpha-return-84077-incoming=patchwork.ozlabs.org@sourceware.org;\n\treceiver=<UNKNOWN>)",
            "ozlabs.org; dkim=pass (1024-bit key;\n\tsecure) header.d=sourceware.org header.i=@sourceware.org\n\theader.b=\"qslhSy15\"; dkim-atps=neutral",
            "sourceware.org; auth=none"
        ],
        "Received": [
            "from sourceware.org (server1.sourceware.org [209.132.180.131])\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 3xkRy85d8Zz9s3w\n\tfor <incoming@patchwork.ozlabs.org>;\n\tSat,  2 Sep 2017 04:06:24 +1000 (AEST)",
            "(qmail 87655 invoked by alias); 1 Sep 2017 18:01:03 -0000",
            "(qmail 87596 invoked by uid 89); 1 Sep 2017 18:01:02 -0000"
        ],
        "DomainKey-Signature": "a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id\n\t:list-unsubscribe:list-subscribe:list-archive:list-post\n\t:list-help:sender:from:to:subject:date:message-id:in-reply-to\n\t:references; q=dns; s=default; b=Du4ZDHZVbPXQsB5v+IuKp4qSrYA4ZkG\n\tq7scIjrc5deyHeUzfmabRtwQfZnoU1Jog8h2PeRNOyPad5YYRP4q/BOayMX5imfY\n\tGWb0iD2eYvSDRkGIBO/8glE37+ieNkqfXF6j6FdqneeeeQ5AbkA3vez9Zr5RsmRT\n\tWY8145nHNsTU=",
        "DKIM-Signature": "v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id\n\t:list-unsubscribe:list-subscribe:list-archive:list-post\n\t:list-help:sender:from:to:subject:date:message-id:in-reply-to\n\t:references; s=default; bh=Fm9jtsrUVjw12PwTUvcP94D8sO8=; b=qslhS\n\ty15AVs+2iLLdH0C1Dc+0Bde+q9+88sF2kNXm7W4RnFDy3wt4mQZVZCKYmqwOE9ZN\n\tx14IWPi/j35zmq3xHQ+BaPrDQtsIy2k3WyhP0ki4VL/Iorj8kDp2gi7zib2dr9Ow\n\tAxpqNEI1G7u0/fVCijXZo1wV5R5J/IflxCpx88=",
        "Mailing-List": "contact libc-alpha-help@sourceware.org; run by ezmlm",
        "Precedence": "bulk",
        "List-Id": "<libc-alpha.sourceware.org>",
        "List-Unsubscribe": "<mailto:libc-alpha-unsubscribe-incoming=patchwork.ozlabs.org@sourceware.org>",
        "List-Subscribe": "<mailto:libc-alpha-subscribe@sourceware.org>",
        "List-Archive": "<http://sourceware.org/ml/libc-alpha/>",
        "List-Post": "<mailto:libc-alpha@sourceware.org>",
        "List-Help": "<mailto:libc-alpha-help@sourceware.org>,\n\t<http://sourceware.org/ml/#faqs>",
        "Sender": "libc-alpha-owner@sourceware.org",
        "X-Virus-Found": "No",
        "X-Spam-SWARE-Status": "No, score=-26.2 required=5.0 tests=BAYES_00,\n\tFREEMAIL_FROM, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2,\n\tGIT_PATCH_3,\n\tSPF_SOFTFAIL autolearn=ham version=3.3.2 spammy=H*m:gmail",
        "X-HELO": "mga02.intel.com",
        "X-ExtLoop1": "1",
        "From": "\"H.J. Lu\" <hjl.tools@gmail.com>",
        "To": "libc-alpha@sourceware.org",
        "Subject": "[PATCH 24/58] Hide __chmod and __mkdir [BZ #18822]",
        "Date": "Fri,  1 Sep 2017 10:59:55 -0700",
        "Message-Id": "<20170901180029.9527-25-hjl.tools@gmail.com>",
        "In-Reply-To": "<20170901180029.9527-1-hjl.tools@gmail.com>",
        "References": "<20170901180029.9527-1-hjl.tools@gmail.com>"
    },
    "content": "Hide internal __chmod and __mkdir functions to allow direct access\nwithin libc.so and libc.a without using GOT nor PLT.\n\n\t[BZ #18822]\n\t* include/sys/stat.h (__chmod): Add libc_hidden_proto.\n\t(__mkdir): Likewise.\n\t* io/chmod.c (__chmod): Add libc_hidden_def.\n\t* io/mkdir.c (__mkdir): Likewise.\n\t* sysdeps/mach/hurd/chmod.c (__chmod): Likewise.\n\t* sysdeps/mach/hurd/mkdir.c (__mkdir): Likewise.\n\t* sysdeps/unix/sysv/linux/generic/chmod.c (__chmod): Likewise.\n\t* sysdeps/unix/sysv/linux/generic/mkdir.c (__mkdir): Likewise.\n---\n include/sys/stat.h                      | 2 ++\n io/chmod.c                              | 1 +\n io/mkdir.c                              | 1 +\n sysdeps/mach/hurd/chmod.c               | 1 +\n sysdeps/mach/hurd/mkdir.c               | 1 +\n sysdeps/unix/sysv/linux/generic/chmod.c | 2 ++\n sysdeps/unix/sysv/linux/generic/mkdir.c | 2 ++\n 7 files changed, 10 insertions(+)",
    "diff": "diff --git a/include/sys/stat.h b/include/sys/stat.h\nindex 4f31c00eca..eb44754185 100644\n--- a/include/sys/stat.h\n+++ b/include/sys/stat.h\n@@ -7,9 +7,11 @@ extern int __stat (const char *__file, struct stat *__buf);\n extern int __fstat (int __fd, struct stat *__buf);\n extern int __lstat (const char *__file, struct stat *__buf);\n extern int __chmod (const char *__file, __mode_t __mode);\n+libc_hidden_proto (__chmod)\n extern int __fchmod (int __fd, __mode_t __mode);\n extern __mode_t __umask (__mode_t __mask);\n extern int __mkdir (const char *__path, __mode_t __mode);\n+libc_hidden_proto (__mkdir)\n extern int __mknod (const char *__path,\n \t\t    __mode_t __mode, __dev_t __dev);\n #if IS_IN (libc) || IS_IN (rtld)\ndiff --git a/io/chmod.c b/io/chmod.c\nindex 0b85565ec2..3cacbf612f 100644\n--- a/io/chmod.c\n+++ b/io/chmod.c\n@@ -35,4 +35,5 @@ __chmod (const char *file, mode_t mode)\n }\n stub_warning (chmod)\n \n+libc_hidden_def (__chmod)\n weak_alias (__chmod, chmod)\ndiff --git a/io/mkdir.c b/io/mkdir.c\nindex 0b8499a707..43a790de33 100644\n--- a/io/mkdir.c\n+++ b/io/mkdir.c\n@@ -36,4 +36,5 @@ __mkdir (const char *path, mode_t mode)\n }\n stub_warning (mkdir)\n \n+libc_hidden_def (__mkdir)\n weak_alias (__mkdir, mkdir)\ndiff --git a/sysdeps/mach/hurd/chmod.c b/sysdeps/mach/hurd/chmod.c\nindex 943f9855d4..612e62d0b2 100644\n--- a/sysdeps/mach/hurd/chmod.c\n+++ b/sysdeps/mach/hurd/chmod.c\n@@ -35,4 +35,5 @@ __chmod (const char *file, mode_t mode)\n   return 0;\n }\n \n+libc_hidden_def (__chmod)\n weak_alias (__chmod, chmod)\ndiff --git a/sysdeps/mach/hurd/mkdir.c b/sysdeps/mach/hurd/mkdir.c\nindex 58c2ac4291..1efac949f6 100644\n--- a/sysdeps/mach/hurd/mkdir.c\n+++ b/sysdeps/mach/hurd/mkdir.c\n@@ -40,4 +40,5 @@ __mkdir (const char *file_name, mode_t mode)\n   return 0;\n }\n \n+libc_hidden_def (__mkdir)\n weak_alias (__mkdir, mkdir)\ndiff --git a/sysdeps/unix/sysv/linux/generic/chmod.c b/sysdeps/unix/sysv/linux/generic/chmod.c\nindex 41d6d9851f..551c67cd07 100644\n--- a/sysdeps/unix/sysv/linux/generic/chmod.c\n+++ b/sysdeps/unix/sysv/linux/generic/chmod.c\n@@ -28,4 +28,6 @@ __chmod (const char *file, mode_t mode)\n {\n   return INLINE_SYSCALL (fchmodat, 3, AT_FDCWD, file, mode);\n }\n+\n+libc_hidden_def (__chmod)\n weak_alias (__chmod, chmod)\ndiff --git a/sysdeps/unix/sysv/linux/generic/mkdir.c b/sysdeps/unix/sysv/linux/generic/mkdir.c\nindex 6571d29ca3..7eebe90ba7 100644\n--- a/sysdeps/unix/sysv/linux/generic/mkdir.c\n+++ b/sysdeps/unix/sysv/linux/generic/mkdir.c\n@@ -30,4 +30,6 @@ __mkdir (const char *path, mode_t mode)\n {\n   return INLINE_SYSCALL (mkdirat, 3, AT_FDCWD, path, mode);\n }\n+\n+libc_hidden_def (__mkdir)\n weak_alias (__mkdir, mkdir)\n",
    "prefixes": [
        "24/58"
    ]
}