Re: SO_RCVTIMEO, SO_SNDTIMEO

Steve Whitehouse (steve@gw.chygwyn.com)
Tue, 13 Feb 2001 10:19:38 +0000 (GMT)


Hi,

They are the maximum amount of time that a send or receive call will
block for. The standard socket error returns apply, so if data has
been sent or received, then the return value will be the amount of
data transferred; if no data has been transferred and the timeout
has been reached then -1 is returned with errno=EAGAIN 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.

Steve.

>
>
> Hi,
>
> I notice the entities in the subject line have appeared in Linux 2.4.
>
> What is their functional specification? I guess they trigger if no bytes
> are received/send within a consecutive period. How does the app get the
> error? -EPIPE for a blocking read/write? If so, does SIGPIPE
> get raised? Or is -ETIMEDOUT used? ...
>
> TIA,
> Chris
>
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://vger.kernel.org/lkml/
>

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/