From: Wayne Davison Date: Fri, 2 Jan 2004 07:31:02 +0000 (+0000) Subject: No need to conditionally-compile EINTR code -- no other files do this. X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/commitdiff_plain/5c1b7bfd2a2a1e3f19be8040ca7cda5947a853ab No need to conditionally-compile EINTR code -- no other files do this. --- diff --git a/util.c b/util.c index 4ba6caa9..ddb150ad 100644 --- a/util.c +++ b/util.c @@ -197,12 +197,10 @@ static int full_write(int desc, char *ptr, size_t len) total_written = 0; while (len > 0) { - int written = write (desc, ptr, len); + int written = write(desc, ptr, len); if (written < 0) { -#ifdef EINTR if (errno == EINTR) continue; -#endif return written; } total_written += written; @@ -231,13 +229,9 @@ static int safe_read(int desc, char *ptr, size_t len) if (len == 0) return len; -#ifdef EINTR do { n_chars = read(desc, ptr, len); } while (n_chars < 0 && errno == EINTR); -#else - n_chars = read(desc, ptr, len); -#endif return n_chars; }