Matt McCutchen's Web Site
/
rsync
/
rsync.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
da7acc5
)
Turn empty remote args into dot dirs.
author
Wayne Davison
<wayned@samba.org>
Sat, 7 May 2011 19:31:33 +0000
(12:31 -0700)
committer
Wayne Davison
<wayned@samba.org>
Sat, 7 May 2011 19:42:16 +0000
(12:42 -0700)
main.c
patch
|
blob
|
blame
|
history
diff --git
a/main.c
b/main.c
index
de5bc48
..
16b283c
100644
(file)
--- a/
main.c
+++ b/
main.c
@@
-1313,6
+1313,9
@@
static int start_client(int argc, char *argv[])
remote_argc = argc = 1;
}
remote_argc = argc = 1;
}
+ if (!rsync_port && remote_argc && !**remote_argv) /* Turn an empty arg into a dot dir. */
+ *remote_argv = ".";
+
if (am_sender) {
char *dummy_host;
int dummy_port = rsync_port;
if (am_sender) {
char *dummy_host;
int dummy_port = rsync_port;
@@
-1348,6
+1351,8
@@
static int start_client(int argc, char *argv[])
rprintf(FERROR, "All source args must use the same port number.\n");
exit_cleanup(RERR_SYNTAX);
}
rprintf(FERROR, "All source args must use the same port number.\n");
exit_cleanup(RERR_SYNTAX);
}
+ if (!rsync_port && !*arg) /* Turn an empty arg into a dot dir. */
+ arg = ".";
remote_argv[i] = arg;
}
}
remote_argv[i] = arg;
}
}