]> granicus.if.org Git - python/commitdiff
After hearing from someone who gave up on timeout sockets due to a
authorGuido van Rossum <guido@python.org>
Sat, 13 Dec 2003 22:12:53 +0000 (22:12 +0000)
committerGuido van Rossum <guido@python.org>
Sat, 13 Dec 2003 22:12:53 +0000 (22:12 +0000)
mistake in his code, I'm adding a note explaining that you should call
settimeout() before connect().

Doc/lib/libsocket.tex

index 09c4c8d63ada461278143dc6eece71f8d569a4d5..1c48108f6d02a33ac0553b55e320204900c780a1 100644 (file)
@@ -625,6 +625,10 @@ method should only be used when the socket is in blocking mode; in
 timeout or non-blocking mode file operations that cannot be completed
 immediately will fail.
 
+Note that the \method{connect()} operation is subject to the timeout
+setting, and in general it is recommended to call
+\method{settimeout()} before calling \method{connect()}.
+
 \begin{methoddesc}[socket]{setsockopt}{level, optname, value}
 Set the value of the given socket option (see the \UNIX{} manual page
 \manpage{setsockopt}{2}).  The needed symbolic constants are defined in