Kaydet (Commit) 07fda7e3 authored tarafından Dave Cole's avatar Dave Cole

Updated the socketpair() docstring and documentation to explain that the

default famility is AF_UNIX if defined for the platform, otherwise the
default is AF_INET.
üst 0fc85754
...@@ -307,8 +307,9 @@ success, a new \class{SSLObject} is returned. ...@@ -307,8 +307,9 @@ success, a new \class{SSLObject} is returned.
Build a pair of connected socket objects using the given address Build a pair of connected socket objects using the given address
family, socket type and protocol number. Address family, socket type family, socket type and protocol number. Address family, socket type
and protocol number are as for the \function{socket()} function above. and protocol number are as for the \function{socket()} function above.
Availability: \UNIX. The default family is AF_UNIX if defined for the platform, otherwise
\versionadded{2.4} the default is AF_INET.
Availability: \UNIX. \versionadded{2.4}
\end{funcdesc} \end{funcdesc}
\begin{funcdesc}{fromfd}{fd, family, type\optional{, proto}} \begin{funcdesc}{fromfd}{fd, family, type\optional{, proto}}
......
...@@ -3011,7 +3011,8 @@ Return the protocol number for the named protocol. (Rarely used.)"); ...@@ -3011,7 +3011,8 @@ Return the protocol number for the named protocol. (Rarely used.)");
#ifdef HAVE_SOCKETPAIR #ifdef HAVE_SOCKETPAIR
/* Create a pair of sockets using the socketpair() function. /* Create a pair of sockets using the socketpair() function.
Arguments as for socket(). */ Arguments as for socket() except the default family is AF_UNIX if
defined for the platform, otherwise the default is AF_INET. */
/*ARGSUSED*/ /*ARGSUSED*/
static PyObject * static PyObject *
...@@ -3058,7 +3059,8 @@ PyDoc_STRVAR(socketpair_doc, ...@@ -3058,7 +3059,8 @@ PyDoc_STRVAR(socketpair_doc,
\n\ \n\
Create a pair of socket objects from the sockets returned by the platform\n\ Create a pair of socket objects from the sockets returned by the platform\n\
socketpair() function.\n\ socketpair() function.\n\
The arguments are the same as for socket()."); The arguments are the same as for socket() except the default family is\n\
AF_UNIX if defined for the platform, otherwise the default is AF_INET.");
#endif /* HAVE_SOCKETPAIR */ #endif /* HAVE_SOCKETPAIR */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment