Re: UDP recvmsg blocks after select(), 2.6 bug?

H. Peter Anvin
2004-10-21T05:18:50Z

Chris Friesen wrote:
> H. Peter Anvin wrote:
>
>> The whole point is that it doesn't break the *documented* interface.
>
>
> In my view (and apparently others, as has been verified in current apps
> using blocking sockets), current behaviour *does* break the documented
> interface.
>
> The man page for select says:
>
> "Those listed in readfds will be watched to see if characters
> become available for reading (more precisely, to see if a read will not
> block..."
>
> If I'm the only one touching the socket, select returns with it
> readable, and I block when calling recvmsg, then by definition that
> behaviour does not match the documented interface.
>

I'm talking about returning -1, EIO.

-hpa