The patches for 3.0.0pre7.
[rsync/rsync-patches.git] / preallocate.diff
index 6c43dbe..f59b856 100644 (file)
@@ -24,7 +24,7 @@ diff --git a/configure.in b/configure.in
 diff --git a/options.c b/options.c
 --- a/options.c
 +++ b/options.c
-@@ -71,6 +71,7 @@ int remove_source_files = 0;
+@@ -72,6 +72,7 @@ int remove_source_files = 0;
  int one_file_system = 0;
  int protocol_version = PROTOCOL_VERSION;
  int sparse_files = 0;
@@ -32,7 +32,7 @@ diff --git a/options.c b/options.c
  int do_compression = 0;
  int def_compress_level = Z_DEFAULT_COMPRESSION;
  int am_root = 0; /* 0 = normal, 1 = root, 2 = --super, -1 = --fake-super */
-@@ -222,6 +223,7 @@ static void print_rsync_version(enum logcode f)
+@@ -223,6 +224,7 @@ static void print_rsync_version(enum logcode f)
        char const *links = "no ";
        char const *iconv = "no ";
        char const *ipv6 = "no ";
@@ -40,7 +40,7 @@ diff --git a/options.c b/options.c
        STRUCT_STAT *dumstat;
  
  #if SUBPROTOCOL_VERSION != 0
-@@ -251,6 +253,9 @@ static void print_rsync_version(enum logcode f)
+@@ -252,6 +254,9 @@ static void print_rsync_version(enum logcode f)
  #ifdef ICONV_OPTION
        iconv = "";
  #endif
@@ -50,7 +50,7 @@ diff --git a/options.c b/options.c
  
        rprintf(f, "%s  version %s  protocol version %d%s\n",
                RSYNC_NAME, RSYNC_VERSION, PROTOCOL_VERSION, subprotocol);
-@@ -264,8 +269,8 @@ static void print_rsync_version(enum logcode f)
+@@ -265,8 +270,8 @@ static void print_rsync_version(enum logcode f)
                (int)(sizeof (int64) * 8));
        rprintf(f, "    %ssocketpairs, %shardlinks, %ssymlinks, %sIPv6, batchfiles, %sinplace,\n",
                got_socketpair, hardlinks, links, ipv6, have_inplace);
@@ -61,7 +61,7 @@ diff --git a/options.c b/options.c
  
  #ifdef MAINTAINER_MODE
        rprintf(f, "Panic Action: \"%s\"\n", get_panic_action());
-@@ -352,6 +357,9 @@ void usage(enum logcode F)
+@@ -353,6 +358,9 @@ void usage(enum logcode F)
    rprintf(F,"     --fake-super            store/recover privileged attrs using xattrs\n");
  #endif
    rprintf(F," -S, --sparse                handle sparse files efficiently\n");
@@ -69,9 +69,9 @@ diff --git a/options.c b/options.c
 +  rprintf(F,"     --preallocate           posix_fallocate dest files before writing them\n");
 +#endif
    rprintf(F," -n, --dry-run               perform a trial run with no changes made\n");
-   rprintf(F," -W, --whole-file            copy files whole (without rsync algorithm)\n");
+   rprintf(F," -W, --whole-file            copy files whole (without delta-xfer algorithm)\n");
    rprintf(F," -x, --one-file-system       don't cross filesystem boundaries\n");
-@@ -530,6 +538,7 @@ static struct poptOption long_options[] = {
+@@ -531,6 +539,7 @@ static struct poptOption long_options[] = {
    {"max-size",         0,  POPT_ARG_STRING, &max_size_arg, OPT_MAX_SIZE, 0, 0 },
    {"min-size",         0,  POPT_ARG_STRING, &min_size_arg, OPT_MIN_SIZE, 0, 0 },
    {"sparse",          'S', POPT_ARG_NONE,   &sparse_files, 0, 0, 0 },
@@ -79,7 +79,7 @@ diff --git a/options.c b/options.c
    {"inplace",          0,  POPT_ARG_NONE,   &inplace, 0, 0, 0 },
    {"append",           0,  POPT_ARG_NONE,   0, OPT_APPEND, 0, 0 },
    {"append-verify",    0,  POPT_ARG_VAL,    &append_mode, 2, 0, 0 },
-@@ -1287,6 +1296,15 @@ int parse_arguments(int *argc_p, const char ***argv_p, int frommain)
+@@ -1289,6 +1298,15 @@ int parse_arguments(int *argc_p, const char ***argv_p, int frommain)
        }
  #endif
  
@@ -95,7 +95,7 @@ diff --git a/options.c b/options.c
        if (write_batch && read_batch) {
                snprintf(err_buf, sizeof err_buf,
                        "--write-batch and --read-batch can not be used together\n");
-@@ -1991,6 +2009,9 @@ void server_options(char **args, int *argc_p)
+@@ -1999,6 +2017,9 @@ void server_options(char **args, int *argc_p)
        else if (remove_source_files)
                args[ac++] = "--remove-sent-files";
  
@@ -180,7 +180,7 @@ diff --git a/rsync.yo b/rsync.yo
   -S, --sparse                handle sparse files efficiently
 +     --preallocate           posix_fallocate dest files before writing
   -n, --dry-run               perform a trial run with no changes made
-  -W, --whole-file            copy files whole (without rsync algorithm)
+  -W, --whole-file            copy files whole (w/o delta-xfer algorithm)
   -x, --one-file-system       don't cross filesystem boundaries
 @@ -1023,6 +1024,19 @@ NOTE: Don't use this option when the destination is a Solaris "tmpfs"
  filesystem. It doesn't seem to handle seeks over null regions