From: Wayne Davison Date: Sun, 30 Jan 2005 10:06:18 +0000 (+0000) Subject: The --delete-during processing only happens during the first phase X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/commitdiff_plain/c93fad5ee084ba006af61beda417368c6740dff4 The --delete-during processing only happens during the first phase (not the redo phase). We also call delete_in_dir(NULL, NULL) to make sure that all the local filter files get popped. --- diff --git a/generator.c b/generator.c index 88e369e6..afa64362 100644 --- a/generator.c +++ b/generator.c @@ -315,7 +315,7 @@ static void recv_generator(char *fname, struct file_list *flist, if (set_perms(fname, file, statret ? NULL : &st, 0) && verbose && f_out != -1) rprintf(FINFO, "%s/\n", safe_fname(fname)); - if (delete_during && f_out != -1 + if (delete_during && f_out != -1 && csum_length != SUM_LENGTH && (file->flags & FLAG_DEL_START)) delete_in_dir(flist, fname); return; @@ -651,6 +651,8 @@ void generate_files(int f_out, struct file_list *flist, char *local_name, recv_generator(local_name ? local_name : f_name_to(file, fbuf), flist, file, i, f_out, f_out_name); } + if (delete_during) + delete_in_dir(NULL, NULL); phase++; csum_length = SUM_LENGTH;