]> git.puffer.fish Git - mirror/frr.git/commitdiff
2005-02-17 Andrew J. Schorr <ajschorr@alumni.princeton.edu>
authorajs <ajs>
Thu, 17 Feb 2005 20:07:22 +0000 (20:07 +0000)
committerajs <ajs>
Thu, 17 Feb 2005 20:07:22 +0000 (20:07 +0000)
* stream.c: (stream_read_try) Use new ERRNO_IO_RETRY macro.

lib/ChangeLog
lib/stream.c

index 40e73ff7b8df21ea4c8df208b8e695ff085f8b58..c4054d00b9707d686ff6062d0bd9a936d83005dc 100644 (file)
@@ -1,3 +1,7 @@
+2005-02-17 Andrew J. Schorr <ajschorr@alumni.princeton.edu>
+
+       * stream.c: (stream_read_try) Use new ERRNO_IO_RETRY macro.
+
 2005-02-17 Andrew J. Schorr <ajschorr@alumni.princeton.edu>
 
        * network.h: Define a new ERRNO_IO_RETRY macro to test whether an I/O
index 7e75f0da7797e5b86a8f69668408b7d6e681f585..a50835eb6423939c84d21f938366328b65e704c3 100644 (file)
@@ -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