unix: handle EWOULDBLOCK in uv__read()

This commit is contained in:
Ben Noordhuis 2012-04-21 05:57:49 +02:00
parent 01cc491853
commit cf6dc082ca

View File

@ -562,7 +562,7 @@ static void uv__read(uv_stream_t* stream) {
if (nread < 0) {
/* Error */
if (errno == EAGAIN) {
if (errno == EAGAIN || errno == EWOULDBLOCK) {
/* Wait for the next one. */
if (stream->flags & UV_READING) {
ev_io_start(ev, &stream->read_watcher);