summaryrefslogtreecommitdiff
path: root/rsync.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>1997-12-16 17:59:49 +0000
committerAndrew Tridgell <tridge@samba.org>1997-12-16 17:59:49 +0000
commitd966ee254a2cc44158bb070c6df0a61a808cbc44 (patch)
tree4185168c18a76ef8bd2780b9ac8164c313853bab /rsync.c
parent97d6916e2df3d6f935e4d57f162a44a77377064c (diff)
downloadrsync-d966ee254a2cc44158bb070c6df0a61a808cbc44.tar.gz
rsync-d966ee254a2cc44158bb070c6df0a61a808cbc44.tar.bz2
rsync-d966ee254a2cc44158bb070c6df0a61a808cbc44.zip
fixed a nasty bug in the handling of the --delete option when there
are duplicate file names in the list of files to be transferred (eg. the user specifies the same file twice).
Diffstat (limited to 'rsync.c')
-rw-r--r--rsync.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/rsync.c b/rsync.c
index 38bbdcde..f961a5dd 100644
--- a/rsync.c
+++ b/rsync.c
@@ -548,10 +548,10 @@ static void delete_files(struct file_list *flist)
strncmp(flist->files[j].name,last_name, strlen(last_name))==0)
continue;
last_name = flist->files[j].name;
+ if (!(local_file_list = send_file_list(-1,1,&last_name)))
+ continue;
if (verbose > 1)
fprintf(FINFO,"deleting in %s\n", last_name);
- if (!(local_file_list = send_file_list(-1,1,&last_name)))
- return;
for (i=local_file_list->count-1;i>=0;i--) {
if (!local_file_list->files[i].name) continue;