diff Doc/lib/libsocket.tex @ 37371:492044034a87 legacy-trunk

Bug #1460564: document that socket.fromfd() duplicates the given file descriptor.
author Georg Brandl <georg@python.org>
date Sat, 01 Apr 2006 07:33:08 +0000
parents 251ecec04f1b
children 464265c1d08b
line wrap: on
line diff
--- a/Doc/lib/libsocket.tex	Sat Apr 01 07:23:08 2006 +0000
+++ b/Doc/lib/libsocket.tex	Sat Apr 01 07:33:08 2006 +0000
@@ -317,10 +317,11 @@
 \end{funcdesc}
 
 \begin{funcdesc}{fromfd}{fd, family, type\optional{, proto}}
-Build a socket object from an existing file descriptor (an integer as
-returned by a file object's \method{fileno()} method).  Address family,
-socket type and protocol number are as for the \function{socket()} function
-above.  The file descriptor should refer to a socket, but this is not
+Duplicate the file descriptor \var{fd} (an integer as returned by a file
+object's \method{fileno()} method) and build a socket object from the
+result.  Address family, socket type and protocol number are as for the
+\function{socket()} function above.
+The file descriptor should refer to a socket, but this is not
 checked --- subsequent operations on the object may fail if the file
 descriptor is invalid.  This function is rarely needed, but can be
 used to get or set socket options on a socket passed to a program as