aboutsummaryrefslogtreecommitdiffstats
path: root/main.c
diff options
context:
space:
mode:
authorWayne Davison <wayned@samba.org>2004-08-05 18:17:44 +0000
committerWayne Davison <wayned@samba.org>2004-08-05 18:17:44 +0000
commite5a96f0f5432843c0412b24550012e00fafe0da4 (patch)
tree3eb2fcce3ee6815ee2331796c9b844ac42f41664 /main.c
parentd73e7f6eddb5a78d24a56852bc817c2a8f82fe89 (diff)
downloadandroid_external_rsync-e5a96f0f5432843c0412b24550012e00fafe0da4.tar.gz
android_external_rsync-e5a96f0f5432843c0412b24550012e00fafe0da4.tar.bz2
android_external_rsync-e5a96f0f5432843c0412b24550012e00fafe0da4.zip
In get_local_name(), if we would have created the destination dir but
were prevented by dry_run being set, increment dry_run so that the generator knows that all the files are missing.
Diffstat (limited to 'main.c')
-rw-r--r--main.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/main.c b/main.c
index 1f2cee36..412c2e2d 100644
--- a/main.c
+++ b/main.c
@@ -379,9 +379,13 @@ static char *get_local_name(struct file_list *flist,char *name)
if (do_mkdir(name,0777 & ~orig_umask) != 0) {
rsyserr(FERROR, errno, "mkdir %s failed", full_fname(name));
exit_cleanup(RERR_FILEIO);
- } else {
- if (verbose > 0)
- rprintf(FINFO,"created directory %s\n",name);
+ }
+ if (verbose > 0)
+ rprintf(FINFO, "created directory %s\n", name);
+
+ if (dry_run) {
+ dry_run++;
+ return NULL;
}
if (!push_dir(name)) {