[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Non-blocking HTTP request with socket.http and copas
- From: Paul K <paul@...>
- Date: Mon, 28 Jul 2014 00:09:17 +0000
> I would have expected a zero timeout to behave as unlimited.
As far as I understand, only "nil" and negative values have that
effect (http://w3.impa.br/~diego/software/luasocket/tcp.html#settimeout).
Paul.
On Sun, Jul 27, 2014 at 4:39 PM, Coda Highland <chighland@gmail.com> wrote:
> On Sun, Jul 27, 2014 at 4:20 PM, Paul K <paul@zerobrane.com> wrote:
>>> What's the expected behavior of a zero timeout? I would expect it to
>>> never succeed at all, because no packet ever has zero latency.
>>
>> It would be the same as for a small timeout; I'd expect "nil, timeout"
>> to be returned with copas taking care of that. Even using 0.000001 as
>> the timeout value works, but not 0.
>
> I would have expected a zero timeout to behave as unlimited.
>
> /s/ Adam
>