From: Bruno Haible Date: Fri, 24 Jan 2025 17:34:04 +0000 (+0100) Subject: sys_socket-h tests: Avoid compilation error on Solaris 11.4. X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=76479d8c3036ffeff94792264afd3aa1777bd960;p=gnulib.git sys_socket-h tests: Avoid compilation error on Solaris 11.4. * doc/posix-headers/sys_socket.texi: Update. * tests/test-sys_socket-h.c (main): Don't assume that all platforms that have SOCK_CLOFORK also have MSG_CMSG_CLOFORK. --- diff --git a/ChangeLog b/ChangeLog index cf382941c4..3daf00751d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2025-01-24 Bruno Haible + + sys_socket-h tests: Avoid compilation error on Solaris 11.4. + * doc/posix-headers/sys_socket.texi: Update. + * tests/test-sys_socket-h.c (main): Don't assume that all platforms that + have SOCK_CLOFORK also have MSG_CMSG_CLOFORK. + 2025-01-23 Collin Funk uchar-h-c23: Fix compilation error on OmniOS. diff --git a/doc/posix-headers/sys_socket.texi b/doc/posix-headers/sys_socket.texi index 944f752183..f4f68b22f9 100644 --- a/doc/posix-headers/sys_socket.texi +++ b/doc/posix-headers/sys_socket.texi @@ -81,7 +81,11 @@ This header file does not define the type @code{struct cmsghdr} and the constant @code{SCM_RIGHTS} on some platforms: mingw, MSVC 14. @item -This header file does not define the constants @code{SOCK_CLOFORK} and -@code{MSG_CMSG_CLOFORK} on some platforms: +This header file does not define the constant @code{SOCK_CLOFORK} +on some platforms: glibc 2.39, musl libc, macOS, FreeBSD, NetBSD, OpenBSD, AIX, Solaris 11.3, Cygwin, mingw, MSVC, Android. +@item +This header file does not define the constant @code{MSG_CMSG_CLOFORK} +on some platforms: +glibc 2.39, musl libc, macOS, FreeBSD, NetBSD, OpenBSD, AIX, Solaris 11.4, Cygwin, mingw, MSVC, Android. @end itemize diff --git a/tests/test-sys_socket-h.c b/tests/test-sys_socket-h.c index 5644f141a8..fffd44ecad 100644 --- a/tests/test-sys_socket-h.c +++ b/tests/test-sys_socket-h.c @@ -165,7 +165,7 @@ main (void) #ifdef MSG_CMSG_CLOEXEC case MSG_CMSG_CLOEXEC: #endif -#ifdef SOCK_CLOFORK +#ifdef MSG_CMSG_CLOFORK case MSG_CMSG_CLOFORK: #endif case MSG_DONTROUTE: