diff --git a/mercurial/osutil.c b/mercurial/osutil.c index 5907ed2b56fb6b0545fa0711b208c49704730a55_bWVyY3VyaWFsL29zdXRpbC5j..3d23700cf4a9f6248872beaf8dabbabc5b59fea9_bWVyY3VyaWFsL29zdXRpbC5j 100644 --- a/mercurial/osutil.c +++ b/mercurial/osutil.c @@ -653,4 +653,7 @@ /* * recvfds() simply does not release GIL during blocking io operation because * command server is known to be single-threaded. + * + * Old systems such as Solaris don't provide CMSG_LEN, msg_control, etc. + * Currently, recvfds() is not supported on these platforms. */ @@ -656,4 +659,5 @@ */ +#ifdef CMSG_LEN static ssize_t recvfdstobuf(int sockfd, int **rfds, void *cbuf, size_t cbufsize) { @@ -713,6 +717,7 @@ return NULL; } +#endif /* CMSG_LEN */ #endif /* ndef _WIN32 */ static PyObject *listdir(PyObject *self, PyObject *args, PyObject *kwargs) @@ -881,6 +886,7 @@ {"statfiles", (PyCFunction)statfiles, METH_VARARGS | METH_KEYWORDS, "stat a series of files or symlinks\n" "Returns None for non-existent entries and entries of other types.\n"}, +#ifdef CMSG_LEN {"recvfds", (PyCFunction)recvfds, METH_VARARGS, "receive list of file descriptors via socket\n"}, #endif @@ -884,6 +890,7 @@ {"recvfds", (PyCFunction)recvfds, METH_VARARGS, "receive list of file descriptors via socket\n"}, #endif +#endif #ifdef __APPLE__ { "isgui", (PyCFunction)isgui, METH_NOARGS,