]> git.ipfire.org Git - thirdparty/man-pages.git/commitdiff
socket.7: Explain effect of SO_SNDTIMEO for connect()
authorAndi Kleen <andi@firstfloor.org>
Fri, 9 Nov 2012 05:58:36 +0000 (06:58 +0100)
committerMichael Kerrisk <mtk.manpages@gmail.com>
Fri, 9 Nov 2012 05:59:57 +0000 (06:59 +0100)
When SO_SNDTIMEO is set before connect(), then connect()
may return EWOULDBLOCK when the timeout fires.

Signed-off-by: Andi Kleen <ak@linux.intel.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
man7/socket.7

index 7097ae2fc71f4fb372ce905715dd48d330e1d5d2..ec1054a59b3dcb9ed83692ecef0f9efd7275cc46 100644 (file)
@@ -459,10 +459,14 @@ will be the amount of data transferred; if no data has been transferred
 and the timeout has been reached then \-1 is returned with
 .I errno
 set to
-.B EAGAIN
+.BR EAGAIN
 or
-.B EWOULDBLOCK
+.BR EWOULDBLOCK ,
 .\" in fact to EAGAIN
+or
+.B EINPROGRESS
+(for
+.BR connect (2))
 just as if the socket was specified to be nonblocking.
 If the timeout is set to zero (the default)
 then the operation will never timeout.
@@ -755,6 +759,7 @@ library.
 .\" This man page was written by Andi Kleen.
 .SH "SEE ALSO"
 .BR getsockopt (2),
+.BR connect (2),
 .BR setsockopt (2),
 .BR socket (2),
 .BR capabilities (7),