Fixed a failing hunk.
authorWayne Davison <wayned@samba.org>
Sat, 15 Sep 2007 20:00:22 +0000 (20:00 +0000)
committerWayne Davison <wayned@samba.org>
Sat, 15 Sep 2007 20:00:22 +0000 (20:00 +0000)
omit-dir-changes.diff

index bd4fca26924801605a9cd52086ca1c1f9a402a9b..05f77081cbf316adb5affcc7b287f118b06fa548 100644 (file)
@@ -17,7 +17,7 @@ To use this patch, run these commands for a successful build:
  extern int uid_ndx;
  extern int gid_ndx;
  extern int delete_mode;
-@@ -555,6 +556,7 @@ void itemize(const char *fnamecmp, struc
+@@ -554,6 +555,7 @@ void itemize(const char *fnamecmp, struc
                int keep_time = !preserve_times ? 0
                    : S_ISDIR(file->mode) ? preserve_times > 1
                    : !S_ISLNK(file->mode);
@@ -25,7 +25,7 @@ To use this patch, run these commands for a successful build:
  
                if (S_ISREG(file->mode) && F_LENGTH(file) != sxp->st.st_size)
                        iflags |= ITEM_REPORT_SIZE;
-@@ -565,10 +567,11 @@ void itemize(const char *fnamecmp, struc
+@@ -564,10 +566,11 @@ void itemize(const char *fnamecmp, struc
                        iflags |= ITEM_REPORT_TIME;
                if (!BITS_EQUAL(sxp->st.st_mode, file->mode, CHMOD_BITS))
                        iflags |= ITEM_REPORT_PERMS;
@@ -40,10 +40,10 @@ To use this patch, run these commands for a successful build:
                        iflags |= ITEM_REPORT_GROUP;
  #ifdef SUPPORT_ACLS
                if (preserve_acls && !S_ISLNK(file->mode)) {
-@@ -1235,7 +1238,7 @@ static void recv_generator(char *fname, 
-                               statret = -1;
-                       new_root_dir = 0;
-               }
+@@ -1246,7 +1249,7 @@ static void recv_generator(char *fname, 
+               real_sx = sx;
+               if (file->flags & FLAG_DIR_CREATED)
+                       statret = -1;
 -              if (!preserve_perms) { /* See comment in non-dir code below. */
 +              if (!preserve_perms || omit_dir_changes) { /* See comment in non-dir code below. */
                        file->mode = dest_mode(file->mode, sx.st.st_mode,
@@ -59,7 +59,7 @@ To use this patch, run these commands for a successful build:
  int update_only = 0;
  int cvs_exclude = 0;
  int dry_run = 0;
-@@ -344,6 +345,7 @@ void usage(enum logcode F)
+@@ -345,6 +346,7 @@ void usage(enum logcode F)
    rprintf(F," -D                          same as --devices --specials\n");
    rprintf(F," -t, --times                 preserve modification times\n");
    rprintf(F," -O, --omit-dir-times        omit directories from --times\n");
@@ -67,7 +67,7 @@ To use this patch, run these commands for a successful build:
    rprintf(F,"     --super                 receiver attempts super-user activities\n");
  #ifdef SUPPORT_XATTRS
    rprintf(F,"     --fake-super            store/recover privileged attrs using xattrs\n");
-@@ -480,6 +482,7 @@ static struct poptOption long_options[] 
+@@ -482,6 +484,7 @@ static struct poptOption long_options[] 
    {"omit-dir-times",  'O', POPT_ARG_VAL,    &omit_dir_times, 1, 0, 0 },
    {"no-omit-dir-times",0,  POPT_ARG_VAL,    &omit_dir_times, 0, 0, 0 },
    {"no-O",             0,  POPT_ARG_VAL,    &omit_dir_times, 0, 0, 0 },
@@ -75,7 +75,7 @@ To use this patch, run these commands for a successful build:
    {"modify-window",    0,  POPT_ARG_INT,    &modify_window, OPT_MODIFY_WINDOW, 0, 0 },
    {"super",            0,  POPT_ARG_VAL,    &am_root, 2, 0, 0 },
    {"no-super",         0,  POPT_ARG_VAL,    &am_root, 0, 0, 0 },
-@@ -1430,6 +1433,8 @@ int parse_arguments(int *argc, const cha
+@@ -1446,6 +1449,8 @@ int parse_arguments(int *argc_p, const c
                parse_rule(&filter_list, backup_dir_buf, 0, 0);
        }
  
@@ -84,7 +84,7 @@ To use this patch, run these commands for a successful build:
        if (make_backups && !backup_dir) {
                omit_dir_times = 0; /* Implied, so avoid -O to sender. */
                if (preserve_times > 1)
-@@ -1665,6 +1670,8 @@ void server_options(char **args,int *arg
+@@ -1681,6 +1686,8 @@ void server_options(char **args, int *ar
                        argstr[x++] = 'm';
                if (omit_dir_times)
                        argstr[x++] = 'O';
@@ -103,7 +103,7 @@ To use this patch, run these commands for a successful build:
  extern int am_root;
  extern int am_server;
  extern int am_sender;
-@@ -324,9 +325,11 @@ int set_file_attrs(const char *fname, st
+@@ -327,9 +328,11 @@ int set_file_attrs(const char *fname, st
                        updated = 1;
        }