Small bug fix for the --compare-dest option: when a file's contents
authorDavid Dykstra <dwd@samba.org>
Fri, 2 Apr 1999 18:24:27 +0000 (18:24 +0000)
committerDavid Dykstra <dwd@samba.org>
Fri, 2 Apr 1999 18:24:27 +0000 (18:24 +0000)
hadn't changed but its permissions had, the file wasn't copied but
its permissions were attempted to be set anyway.  Made a change to
skip setting the permissions in that case.

generator.c

index 8b0eeab..d77e7b5 100644 (file)
@@ -317,7 +317,8 @@ void recv_generator(char *fname,struct file_list *flist,int i,int f_out)
        }
 
        if (skip_file(fname, file, &st)) {
-               set_perms(fname,file,&st,1);
+               if (fnamecmp == fname)
+                       set_perms(fname,file,&st,1);
                return;
        }