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

From: Martijn Sipkema
Date: Wed Oct 06 2004 - 16:24:54 EST


From: "Chris Friesen" <cfriesen@xxxxxxxxxxxxxxxxxx>
Sent: Wednesday, October 06, 2004 21:10
[...]
> From what Andries posted, we can't block. If select says its readable, we can
> "return data, an end-of-file indication, or an error other than one
> indicating that it is blocked".
>
> We have no data, network sockets don't have end-of-file indication (or would
> returning a length of zero count?), and there is no other suitable errno that I saw.

The current behavious is definately not POSIX compliant; returning an error
is better in any case and that error does not necessarily have to be listed in the
ERRORS section of the recvmsg() function description in the standard.
Returning EIO would be an option and is listed as with the errors in POSIX.

--ms


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