Handle a solo_file of a directory for --delete-during.
authorWayne Davison <wayned@samba.org>
Mon, 9 Jun 2008 14:42:03 +0000 (07:42 -0700)
committerWayne Davison <wayned@samba.org>
Mon, 9 Jun 2008 14:42:03 +0000 (07:42 -0700)
generator.c

index 2ae88db..73dc163 100644 (file)
@@ -2210,7 +2210,10 @@ void generate_files(int f_out, const char *local_name)
 
                if (inc_recurse && cur_flist->parent_ndx >= 0) {
                        struct file_struct *fp = dir_flist->files[cur_flist->parent_ndx];
-                       f_name(fp, fbuf);
+                       if (solo_file)
+                               strlcpy(fbuf, solo_file, sizeof fbuf);
+                       else
+                               f_name(fp, fbuf);
                        ndx = cur_flist->ndx_start - 1;
                        recv_generator(fbuf, fp, ndx, itemizing, code, f_out);
                        if (delete_during && dry_run < 2 && !list_only