X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/blobdiff_plain/4403b1332f3264e357a46c1c96853a809dcfcaf8..bd685982389b78a158921b7839bdeca501338d19:/main.c diff --git a/main.c b/main.c index de5bc489..5a06f177 100644 --- a/main.c +++ b/main.c @@ -594,7 +594,7 @@ static char *get_local_name(struct file_list *flist, char *dest_path) if ((*dest_path != '.' || dest_path[1] != '\0') && (check_filter(&daemon_filter_list, FLOG, dest_path, 0) < 0 || check_filter(&daemon_filter_list, FLOG, dest_path, 1) < 0)) { - rprintf(FERROR, "skipping daemon-excluded destination \"%s\"\n", + rprintf(FERROR, "ERROR: daemon has excluded destination \"%s\"\n", dest_path); exit_cleanup(RERR_FILESELECT); } @@ -1313,6 +1313,9 @@ static int start_client(int argc, char *argv[]) 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; @@ -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); } + if (!rsync_port && !*arg) /* Turn an empty arg into a dot dir. */ + arg = "."; remote_argv[i] = arg; } }