summaryrefslogtreecommitdiff
path: root/lib/stream.c
diff options
context:
space:
mode:
authorajs <ajs>2005-02-17 20:07:22 +0000
committerajs <ajs>2005-02-17 20:07:22 +0000
commit53270116df3f54b1f9411f0832567e9effa87593 (patch)
tree08fab8ea890f84694a0f9fcaaf55a13fbf698ef3 /lib/stream.c
parentd7e2a8188f6e9eaccb5e1c1bd7b9d5af79429c0c (diff)
2005-02-17 Andrew J. Schorr <ajschorr@alumni.princeton.edu>
* stream.c: (stream_read_try) Use new ERRNO_IO_RETRY macro.
Diffstat (limited to 'lib/stream.c')
-rw-r--r--lib/stream.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/stream.c b/lib/stream.c
index 7e75f0da..a50835eb 100644
--- a/lib/stream.c
+++ b/lib/stream.c
@@ -624,8 +624,7 @@ stream_read_try(struct stream *s, int fd, size_t size)
return nbytes;
}
/* Error: was it transient (return -2) or fatal (return -1)? */
- return ((errno == EAGAIN) || (errno == EWOULDBLOCK) || (errno == EINTR)) ?
- -2 : -1;
+ return ERRNO_IO_RETRY(errno) ? -2 : -1;
}
/* Read up to smaller of size or SIZE_REMAIN() bytes to the stream, starting