From a855c926fe865911611a82eedaebaf0f780f2bbd Mon Sep 17 00:00:00 2001 From: "A. Wilcox" Date: Thu, 1 Feb 2018 18:31:59 -0600 Subject: socket: add __cmsg_nxthdr --- CHANGELOG.rst | 6 ++++++ libgcompat/socket.c | 10 ++++++++++ 2 files changed, 16 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index a35657e..7d23a3c 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -25,6 +25,12 @@ malloc * Add __sbrk. +socket +------ + +* Add __cmsg_nxthdr. + + sysctl ------ diff --git a/libgcompat/socket.c b/libgcompat/socket.c index 927ebe4..971a6ba 100644 --- a/libgcompat/socket.c +++ b/libgcompat/socket.c @@ -2,6 +2,16 @@ #include /* NULL */ #include /* recv, recvfrom */ +/** + * Found in the wild needed by libcef. It looks like glibc moved to a + * pure preprocessor-based solution some time ago, but this remains for + * compatibility. + */ +struct cmsghdr *__cmsg_nxthdr(struct msghdr *msg, struct cmsghdr *cmsg) +{ + return CMSG_NXTHDR(msg, cmsg); +} + /** * Receive a message from a connected socket, with buffer overflow checking. * -- cgit v1.2.3-70-g09d2