From: Wayne Davison Date: Sat, 21 Jan 2006 00:36:15 +0000 (+0000) Subject: Allow the -x option to be repeated. X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/commitdiff_plain/243c995f5fea0d239ad292d71685311fd7299225 Allow the -x option to be repeated. --- diff --git a/options.c b/options.c index 63919096..704833a3 100644 --- a/options.c +++ b/options.c @@ -425,7 +425,7 @@ static struct poptOption long_options[] = { {"chmod", 0, POPT_ARG_STRING, &chmod_mode, 0, 0, 0 }, {"ignore-times", 'I', POPT_ARG_NONE, &ignore_times, 0, 0, 0 }, {"size-only", 0, POPT_ARG_NONE, &size_only, 0, 0, 0 }, - {"one-file-system", 'x', POPT_ARG_NONE, &one_file_system, 0, 0, 0 }, + {"one-file-system", 'x', POPT_ARG_NONE, 0, 'x', 0, 0 }, {"update", 'u', POPT_ARG_NONE, &update_only, 0, 0, 0 }, {"existing", 0, POPT_ARG_NONE, &ignore_non_existing, 0, 0, 0 }, {"ignore-non-existing",0,POPT_ARG_NONE, &ignore_non_existing, 0, 0, 0 }, @@ -891,6 +891,10 @@ int parse_arguments(int *argc, const char ***argv, int frommain) quiet++; break; + case 'x': + one_file_system++; + break; + case OPT_SENDER: if (!am_server) { usage(FERROR); @@ -1459,8 +1463,11 @@ void server_options(char **args,int *argc) argstr[x++] = 'I'; if (relative_paths) argstr[x++] = 'R'; - if (one_file_system) + if (one_file_system) { argstr[x++] = 'x'; + if (one_file_system > 1) + argstr[x++] = 'x'; + } if (sparse_files) argstr[x++] = 'S'; if (do_compression)