Fixed failing hunks.
[rsync/rsync-patches.git] / acls.diff
index d5ef5e4..cc45f6f 100644 (file)
--- a/acls.diff
+++ b/acls.diff
@@ -1284,7 +1284,7 @@ ACLs to a non-ACL-supporting disk should complain.
  AC_CONFIG_FILES([Makefile lib/dummy zlib/dummy popt/dummy shconfig])
  AC_OUTPUT
  
---- orig/flist.c       2005-07-27 23:31:12
+--- orig/flist.c       2005-08-17 06:45:07
 +++ flist.c    2005-07-29 02:49:06
 @@ -974,6 +974,8 @@ static struct file_struct *send_file_nam
        file = make_file(fname, flist, f == -2 ? SERVER_FILTERS : ALL_FILTERS);
@@ -1306,7 +1306,7 @@ ACLs to a non-ACL-supporting disk should complain.
        }
        return file;
  }
-@@ -1318,6 +1324,8 @@ struct file_list *recv_file_list(int f)
+@@ -1327,6 +1333,8 @@ struct file_list *recv_file_list(int f)
                        flags |= read_byte(f) << 8;
                file = receive_file_entry(flist, flags, f);
  
@@ -1315,7 +1315,7 @@ ACLs to a non-ACL-supporting disk should complain.
                if (S_ISREG(file->mode))
                        stats.total_size += file->length;
  
-@@ -1340,6 +1348,8 @@ struct file_list *recv_file_list(int f)
+@@ -1349,6 +1357,8 @@ struct file_list *recv_file_list(int f)
  
        clean_flist(flist, relative_paths, 1);
  
@@ -1324,7 +1324,7 @@ ACLs to a non-ACL-supporting disk should complain.
        if (f >= 0) {
                /* Now send the uid/gid list. This was introduced in
                 * protocol version 15 */
---- orig/generator.c   2005-07-28 01:46:25
+--- orig/generator.c   2005-08-17 06:45:07
 +++ generator.c        2005-05-12 23:34:00
 @@ -725,6 +725,10 @@ static void recv_generator(char *fname, 
                if (set_perms(fname, file, statret ? NULL : &st, 0)
@@ -4624,9 +4624,9 @@ ACLs to a non-ACL-supporting disk should complain.
    next;
  }
  
---- orig/options.c     2005-07-28 01:46:25
-+++ options.c  2005-05-12 23:34:38
-@@ -44,6 +44,7 @@ int keep_dirlinks = 0;
+--- orig/options.c     2005-08-27 21:11:26
++++ options.c  2005-08-27 21:15:29
+@@ -43,6 +43,7 @@ int keep_dirlinks = 0;
  int copy_links = 0;
  int preserve_links = 0;
  int preserve_hard_links = 0;
@@ -4634,7 +4634,7 @@ ACLs to a non-ACL-supporting disk should complain.
  int preserve_perms = 0;
  int preserve_devices = 0;
  int preserve_uid = 0;
-@@ -182,6 +183,7 @@ static void print_rsync_version(enum log
+@@ -181,6 +182,7 @@ static void print_rsync_version(enum log
        char const *got_socketpair = "no ";
        char const *have_inplace = "no ";
        char const *hardlinks = "no ";
@@ -4642,7 +4642,7 @@ ACLs to a non-ACL-supporting disk should complain.
        char const *links = "no ";
        char const *ipv6 = "no ";
        STRUCT_STAT *dumstat;
-@@ -198,6 +200,10 @@ static void print_rsync_version(enum log
+@@ -197,6 +199,10 @@ static void print_rsync_version(enum log
        hardlinks = "";
  #endif
  
@@ -4653,7 +4653,7 @@ ACLs to a non-ACL-supporting disk should complain.
  #ifdef SUPPORT_LINKS
        links = "";
  #endif
-@@ -212,9 +218,9 @@ static void print_rsync_version(enum log
+@@ -211,9 +217,9 @@ static void print_rsync_version(enum log
                "Copyright (C) 1996-2005 by Andrew Tridgell and others\n");
        rprintf(f, "<http://rsync.samba.org/>\n");
        rprintf(f, "Capabilities: %d-bit files, %ssocketpairs, "
@@ -4665,7 +4665,7 @@ ACLs to a non-ACL-supporting disk should complain.
  
        /* Note that this field may not have type ino_t.  It depends
         * on the complicated interaction between largefile feature
-@@ -285,6 +291,7 @@ void usage(enum logcode F)
+@@ -284,6 +290,7 @@ void usage(enum logcode F)
    rprintf(F," -H, --hard-links            preserve hard links\n");
    rprintf(F," -K, --keep-dirlinks         treat symlinked dir on receiver as dir\n");
    rprintf(F," -p, --perms                 preserve permissions\n");
@@ -4673,15 +4673,17 @@ ACLs to a non-ACL-supporting disk should complain.
    rprintf(F," -o, --owner                 preserve owner (root only)\n");
    rprintf(F," -g, --group                 preserve group\n");
    rprintf(F," -D, --devices               preserve devices (root only)\n");
-@@ -412,6 +419,7 @@ static struct poptOption long_options[] 
-   {"no-whole-file",    0,  POPT_ARG_VAL,    &whole_file, 0, 0, 0 },
-   {"copy-unsafe-links",0,  POPT_ARG_NONE,   &copy_unsafe_links, 0, 0, 0 },
-   {"perms",           'p', POPT_ARG_NONE,   &preserve_perms, 0, 0, 0 },
-+  {"acls",            'A', POPT_ARG_NONE,   0,              'A', 0, 0 },
-   {"owner",           'o', POPT_ARG_NONE,   &preserve_uid, 0, 0, 0 },
-   {"group",           'g', POPT_ARG_NONE,   &preserve_gid, 0, 0, 0 },
-   {"devices",         'D', POPT_ARG_NONE,   &preserve_devices, 0, 0, 0 },
-@@ -882,6 +890,24 @@ int parse_arguments(int *argc, const cha
+@@ -385,6 +392,9 @@ static struct poptOption long_options[] 
+   {"perms",           'p', POPT_ARG_VAL,    &preserve_perms, 1, 0, 0 },
+   {"no-perms",         0,  POPT_ARG_VAL,    &preserve_perms, 0, 0, 0 },
+   {"no-p",             0,  POPT_ARG_VAL,    &preserve_perms, 0, 0, 0 },
++  {"acls",            'A', POPT_ARG_NONE,   0, 'A', 0, 0 },
++  {"no-acls",          0,  POPT_ARG_VAL,    &preserve_acls, 0, 0, 0 },
++  {"no-A",             0,  POPT_ARG_VAL,    &preserve_acls, 0, 0, 0 },
+   {"times",           't', POPT_ARG_VAL,    &preserve_times, 1, 0, 0 },
+   {"no-times",         0,  POPT_ARG_VAL,    &preserve_times, 0, 0, 0 },
+   {"no-t",             0,  POPT_ARG_VAL,    &preserve_times, 0, 0, 0 },
+@@ -916,6 +926,24 @@ int parse_arguments(int *argc, const cha
                        basis_dir[basis_dir_cnt++] = (char *)arg;
                        break;
  
@@ -4689,6 +4691,7 @@ ACLs to a non-ACL-supporting disk should complain.
 +#ifdef SUPPORT_ACLS
 +                      preserve_acls = 1;
 +                      preserve_perms = 1;
++                      break;
 +#else
 +                      /* FIXME: this should probably be ignored with a
 +                       * warning and then countermeasures taken to
@@ -4700,13 +4703,12 @@ ACLs to a non-ACL-supporting disk should complain.
 +                               am_server ? "server" : "client");
 +                      return 0;
 +#endif /* SUPPORT_ACLS */
-+                      break;
 +
 +
                default:
                        /* A large opt value means that set_refuse_options()
                         * turned this option off. */
-@@ -1305,6 +1331,8 @@ void server_options(char **args,int *arg
+@@ -1329,6 +1357,8 @@ void server_options(char **args,int *arg
  
        if (preserve_hard_links)
                argstr[x++] = 'H';
@@ -4732,9 +4734,9 @@ ACLs to a non-ACL-supporting disk should complain.
        if (verbose > 1 && flags & PERMS_REPORT) {
                enum logcode code = daemon_log_format_has_i || dry_run
                                  ? FCLIENT : FINFO;
---- orig/rsync.h       2005-05-03 17:11:01
+--- orig/rsync.h       2005-08-17 06:45:08
 +++ rsync.h    2005-07-29 02:25:55
-@@ -638,6 +638,44 @@ struct stats {
+@@ -646,6 +646,44 @@ struct stats {
  #include "lib/permstring.h"
  #include "lib/addrinfo.h"
  
@@ -4779,9 +4781,9 @@ ACLs to a non-ACL-supporting disk should complain.
  #include "proto.h"
  
  /* We have replacement versions of these if they're missing. */
---- orig/rsync.yo      2005-07-29 02:47:20
+--- orig/rsync.yo      2005-08-27 21:05:12
 +++ rsync.yo   2004-07-03 20:11:58
-@@ -316,6 +316,7 @@ to the detailed description below for a 
+@@ -318,6 +318,7 @@ to the detailed description below for a 
   -H, --hard-links            preserve hard links
   -K, --keep-dirlinks         treat symlinked dir on receiver as dir
   -p, --perms                 preserve permissions
@@ -4789,7 +4791,7 @@ ACLs to a non-ACL-supporting disk should complain.
   -o, --owner                 preserve owner (root only)
   -g, --group                 preserve group
   -D, --devices               preserve devices (root only)
-@@ -636,6 +637,11 @@ based on the source file's permissions, 
+@@ -665,6 +666,11 @@ based on the source file's permissions, 
  umask setting
  (which is the same behavior as other file-copy utilities, such as cp).