X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/blobdiff_plain/fab9a9c54729984199d20b637ea8cc163c73d2e2..6902ed178ba54c8e1c410519f7ee576ddb42554c:/util.c diff --git a/util.c b/util.c index 50fdaf8e..ada40465 100644 --- a/util.c +++ b/util.c @@ -154,6 +154,7 @@ pid_t local_child(int argc, char **argv,int *f_in,int *f_out) pid_t pid; int to_child_pipe[2]; int from_child_pipe[2]; + extern int read_batch; /* dw */ if (fd_pair(to_child_pipe) < 0 || fd_pair(from_child_pipe) < 0) { @@ -172,7 +173,10 @@ pid_t local_child(int argc, char **argv,int *f_in,int *f_out) extern int am_sender; extern int am_server; - am_sender = !am_sender; + if (read_batch) + am_sender = 0; + else + am_sender = !am_sender; am_server = 1; if (dup2(to_child_pipe[0], STDIN_FILENO) < 0 ||