The branch, master has been updated via e3bc529 Handle EINTR when reading the pre-xfer exec message. from 820f7a7 Send error messages from pre-xfer exec script to the user.
;a=shortlog;h=master - Log ----------------------------------------------------------------- commit e3bc529de9b7d0e98c492677f73a8127a1d74d35 Author: Wayne Davison <way...@samba.org> Date: Sat Jun 4 12:08:18 2011 -0700 Handle EINTR when reading the pre-xfer exec message. ----------------------------------------------------------------------- Summary of changes: clientserver.c | 9 ++++++++- 1 files changed, 8 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/clientserver.c b/clientserver.c index 8fedbe6..91612ea 100644 --- a/clientserver.c +++ b/clientserver.c @@ -374,7 +374,14 @@ static char *finish_pre_exec(pid_t pid, int write_fd, int read_fd, char *request /* Read the stdout from the pre-xfer exec program. This it is only * displayed to the user if the script also returns an error status. */ - for (bp = buf; msglen > 0 && (j = read(read_fd, bp, msglen)) > 0; msglen -= j) { + for (bp = buf; msglen > 0; msglen -= j) { + if ((j = read(read_fd, bp, msglen)) <= 0) { + if (j == 0) + break; + if (errno == EINTR) + continue; + break; /* Just ignore the read error for now... */ + } bp += j; if (j > 1 && bp[-1] == '\n' && bp[-2] == '\r') { bp--; -- The rsync repository. _______________________________________________ rsync-cvs mailing list rsync-cvs@lists.samba.org https://lists.samba.org/mailman/listinfo/rsync-cvs