From 74eccbb1afc7b039d2879b82851334ff24e39cce Mon Sep 17 00:00:00 2001 From: Wayne Davison Date: Mon, 5 Jun 2006 20:57:03 +0000 Subject: [PATCH] Fixed a failing hunk. --- acls.diff | 116 ++++++++++++++++++++++---------------------- early-checksum.diff | 26 +++++----- 2 files changed, 71 insertions(+), 71 deletions(-) diff --git a/acls.diff b/acls.diff index f6fd11b..937f793 100644 --- a/acls.diff +++ b/acls.diff @@ -1422,7 +1422,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. } --- old/generator.c +++ new/generator.c -@@ -36,6 +36,7 @@ extern int recurse; +@@ -35,6 +35,7 @@ extern int do_progress; extern int relative_paths; extern int implied_dirs; extern int keep_dirlinks; @@ -1430,7 +1430,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. extern int preserve_links; extern int preserve_devices; extern int preserve_specials; -@@ -85,6 +86,7 @@ extern long block_size; /* "long" becaus +@@ -84,6 +85,7 @@ extern long block_size; /* "long" becaus extern int max_delete; extern int force_delete; extern int one_file_system; @@ -1438,7 +1438,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. extern struct stats stats; extern dev_t filesystem_dev; extern char *backup_dir; -@@ -317,22 +319,27 @@ static void do_delete_pass(struct file_l +@@ -316,22 +318,27 @@ static void do_delete_pass(struct file_l rprintf(FINFO, " \r"); } @@ -1471,7 +1471,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. int32 iflags, uchar fnamecmp_type, char *xname) { if (statret >= 0) { /* A from-dest-dir statret can == 1! */ -@@ -340,19 +347,23 @@ void itemize(struct file_struct *file, i +@@ -339,19 +346,23 @@ void itemize(struct file_struct *file, i : S_ISDIR(file->mode) ? !omit_dir_times : !S_ISLNK(file->mode); @@ -1500,7 +1500,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. } else iflags |= ITEM_IS_NEW; -@@ -603,7 +614,7 @@ void check_for_finished_hlinks(int itemi +@@ -604,7 +615,7 @@ void check_for_finished_hlinks(int itemi * handling the file, -1 if no dest-linking occurred, or a non-negative * value if we found an alternate basis file. */ static int try_dests_reg(struct file_struct *file, char *fname, int ndx, @@ -1509,7 +1509,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. int maybe_ATTRS_REPORT, enum logcode code) { int save_ignore_times = ignore_times; -@@ -617,7 +628,7 @@ static int try_dests_reg(struct file_str +@@ -618,7 +629,7 @@ static int try_dests_reg(struct file_str do { pathjoin(cmpbuf, MAXPATHLEN, basis_dir[j], fname); @@ -1518,7 +1518,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. continue; switch (match_level) { case 0: -@@ -625,16 +636,20 @@ static int try_dests_reg(struct file_str +@@ -626,16 +637,20 @@ static int try_dests_reg(struct file_str match_level = 1; /* FALL THROUGH */ case 1: @@ -1542,7 +1542,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. continue; best_match = j; match_level = 3; -@@ -651,14 +666,14 @@ static int try_dests_reg(struct file_str +@@ -652,14 +667,14 @@ static int try_dests_reg(struct file_str if (j != best_match) { j = best_match; pathjoin(cmpbuf, MAXPATHLEN, basis_dir[j], fname); @@ -1559,7 +1559,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. cmpbuf, 1, itemizing && verbose > 1, code) < 0) -@@ -667,8 +682,13 @@ static int try_dests_reg(struct file_str +@@ -668,8 +683,13 @@ static int try_dests_reg(struct file_str hard_link_cluster(file, ndx, itemizing, code); } else #endif @@ -1573,8 +1573,8 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. + itemize(file, ndx, 0, sxp, 0, 0, NULL); + } if (verbose > 1 && maybe_ATTRS_REPORT) { - code = logfile_format_has_i || dry_run ? FNAME : FINFO; - rprintf(code, "%s is uptodate\n", fname); + rprintf(FCLIENT, "%s is uptodate\n", fname); + } @@ -685,8 +705,13 @@ static int try_dests_reg(struct file_str } return -1; @@ -1642,8 +1642,8 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. +#endif } if (verbose > 1 && maybe_ATTRS_REPORT) { - code = logfile_format_has_i || dry_run ? FNAME : FINFO; -@@ -776,6 +814,7 @@ static int try_dests_non(struct file_str + rprintf(FCLIENT, "%s is uptodate\n", fname); +@@ -775,6 +813,7 @@ static int try_dests_non(struct file_str } static int phase = 0; @@ -1651,7 +1651,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. /* Acts on the_file_list->file's ndx'th item, whose name is fname. If a dir, * make sure it exists, and has the right permissions/timestamp info. For -@@ -797,7 +836,8 @@ static void recv_generator(char *fname, +@@ -796,7 +835,8 @@ static void recv_generator(char *fname, static int need_fuzzy_dirlist = 0; struct file_struct *fuzzy_file = NULL; int fd = -1, f_copy = -1; @@ -1661,9 +1661,9 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. struct file_struct *back_file = NULL; int statret, real_ret, stat_errno; char *fnamecmp, *partialptr, *backupptr = NULL; -@@ -848,6 +888,9 @@ static void recv_generator(char *fname, - dry_run--; - missing_below = -1; +@@ -852,6 +892,9 @@ static void recv_generator(char *fname, + } else if (!dry_run) + return; } +#ifdef SUPPORT_ACLS + sx.acc_acl = sx.def_acl = NULL; @@ -1671,7 +1671,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. if (dry_run > 1) { statret = -1; stat_errno = ENOENT; -@@ -855,7 +898,7 @@ static void recv_generator(char *fname, +@@ -859,7 +902,7 @@ static void recv_generator(char *fname, char *dn = file->dirname ? file->dirname : "."; if (parent_dirname != dn && strcmp(parent_dirname, dn) != 0) { if (relative_paths && !implied_dirs @@ -1680,7 +1680,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. && create_directory_path(fname) < 0) { rsyserr(FERROR, errno, "recv_generator: mkdir %s failed", -@@ -867,6 +910,10 @@ static void recv_generator(char *fname, +@@ -871,6 +914,10 @@ static void recv_generator(char *fname, } if (fuzzy_basis) need_fuzzy_dirlist = 1; @@ -1691,7 +1691,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. } parent_dirname = dn; -@@ -875,7 +922,7 @@ static void recv_generator(char *fname, +@@ -879,7 +926,7 @@ static void recv_generator(char *fname, need_fuzzy_dirlist = 0; } @@ -1700,7 +1700,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. keep_dirlinks && S_ISDIR(file->mode)); stat_errno = errno; } -@@ -893,8 +940,9 @@ static void recv_generator(char *fname, +@@ -897,8 +944,9 @@ static void recv_generator(char *fname, * mode based on the local permissions and some heuristics. */ if (!preserve_perms) { int exists = statret == 0 @@ -1712,7 +1712,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. } if (S_ISDIR(file->mode)) { -@@ -903,8 +951,8 @@ static void recv_generator(char *fname, +@@ -907,8 +955,8 @@ static void recv_generator(char *fname, * file of that name and it is *not* a directory, then * we need to delete it. If it doesn't exist, then * (perhaps recursively) create it. */ @@ -1723,7 +1723,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. return; statret = -1; } -@@ -913,7 +961,11 @@ static void recv_generator(char *fname, +@@ -917,7 +965,11 @@ static void recv_generator(char *fname, dry_run++; } if (itemizing && f_out != -1) { @@ -1736,8 +1736,8 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. statret ? ITEM_LOCAL_CHANGE : 0, 0, NULL); } if (statret != 0 && do_mkdir(fname,file->mode) < 0 && errno != EEXIST) { -@@ -925,19 +977,19 @@ static void recv_generator(char *fname, - full_fname(fname)); +@@ -937,19 +989,19 @@ static void recv_generator(char *fname, + return; } } - if (set_file_attrs(fname, file, statret ? NULL : &st, 0) @@ -1761,7 +1761,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. if (preserve_links && S_ISLNK(file->mode)) { #ifdef SUPPORT_LINKS -@@ -955,7 +1007,7 @@ static void recv_generator(char *fname, +@@ -967,7 +1019,7 @@ static void recv_generator(char *fname, char lnk[MAXPATHLEN]; int len; @@ -1770,7 +1770,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. && (len = readlink(fname, lnk, MAXPATHLEN-1)) > 0) { lnk[len] = 0; /* A link already pointing to the -@@ -963,10 +1015,10 @@ static void recv_generator(char *fname, +@@ -975,10 +1027,10 @@ static void recv_generator(char *fname, * required. */ if (strcmp(lnk, file->u.link) == 0) { if (itemizing) { @@ -1783,7 +1783,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. maybe_ATTRS_REPORT); if (preserve_hard_links && file->link_u.links) { -@@ -979,9 +1031,9 @@ static void recv_generator(char *fname, +@@ -991,9 +1043,9 @@ static void recv_generator(char *fname, } /* Not the right symlink (or not a symlink), so * delete it. */ @@ -1795,7 +1795,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. statret = -1; } else if (basis_dir[0] != NULL) { if (try_dests_non(file, fname, ndx, itemizing, -@@ -997,7 +1049,7 @@ static void recv_generator(char *fname, +@@ -1009,7 +1061,7 @@ static void recv_generator(char *fname, } } if (preserve_hard_links && file->link_u.links @@ -1804,7 +1804,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. itemizing, code, HL_SKIP)) return; if (do_symlink(file->u.link,fname) != 0) { -@@ -1006,7 +1058,7 @@ static void recv_generator(char *fname, +@@ -1018,7 +1070,7 @@ static void recv_generator(char *fname, } else { set_file_attrs(fname, file, NULL, 0); if (itemizing) { @@ -1813,7 +1813,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. ITEM_LOCAL_CHANGE, 0, NULL); } if (code && verbose) { -@@ -1040,18 +1092,22 @@ static void recv_generator(char *fname, +@@ -1052,18 +1104,22 @@ static void recv_generator(char *fname, itemizing = code = 0; } } @@ -1844,7 +1844,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. statret = -1; if (verbose > 2) { rprintf(FINFO,"mknod(%s,0%o,0x%x)\n", -@@ -1064,7 +1120,7 @@ static void recv_generator(char *fname, +@@ -1076,7 +1132,7 @@ static void recv_generator(char *fname, } else { set_file_attrs(fname, file, NULL, 0); if (itemizing) { @@ -1853,7 +1853,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. ITEM_LOCAL_CHANGE, 0, NULL); } if (code && verbose) -@@ -1076,12 +1132,12 @@ static void recv_generator(char *fname, +@@ -1088,12 +1144,12 @@ static void recv_generator(char *fname, } } else { if (itemizing) @@ -1869,7 +1869,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. } if (!S_ISREG(file->mode)) { -@@ -1115,7 +1171,7 @@ static void recv_generator(char *fname, +@@ -1127,7 +1183,7 @@ static void recv_generator(char *fname, } if (update_only && statret == 0 @@ -1878,7 +1878,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. if (verbose > 1) rprintf(FINFO, "%s is newer\n", fname); return; -@@ -1124,18 +1180,18 @@ static void recv_generator(char *fname, +@@ -1136,18 +1192,18 @@ static void recv_generator(char *fname, fnamecmp = fname; fnamecmp_type = FNAMECMP_FNAME; @@ -1901,7 +1901,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. if (j != -1) { fnamecmp = fnamecmpbuf; fnamecmp_type = j; -@@ -1144,7 +1200,7 @@ static void recv_generator(char *fname, +@@ -1156,7 +1212,7 @@ static void recv_generator(char *fname, } real_ret = statret; @@ -1910,7 +1910,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. if (partial_dir && (partialptr = partial_dir_fname(fname)) != NULL && link_stat(partialptr, &partial_st, 0) == 0 -@@ -1163,7 +1219,7 @@ static void recv_generator(char *fname, +@@ -1175,7 +1231,7 @@ static void recv_generator(char *fname, rprintf(FINFO, "fuzzy basis selected for %s: %s\n", fname, fnamecmpbuf); } @@ -1919,7 +1919,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. statret = 0; fnamecmp = fnamecmpbuf; fnamecmp_type = FNAMECMP_FUZZY; -@@ -1172,7 +1228,7 @@ static void recv_generator(char *fname, +@@ -1184,7 +1240,7 @@ static void recv_generator(char *fname, if (statret != 0) { if (preserve_hard_links && file->link_u.links @@ -1928,7 +1928,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. itemizing, code, HL_SKIP)) return; if (stat_errno == ENOENT) -@@ -1182,31 +1238,44 @@ static void recv_generator(char *fname, +@@ -1194,31 +1250,44 @@ static void recv_generator(char *fname, return; } @@ -1979,7 +1979,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. fnamecmp = partialptr; fnamecmp_type = FNAMECMP_PARTIAL_DIR; statret = 0; -@@ -1230,17 +1299,21 @@ static void recv_generator(char *fname, +@@ -1242,17 +1311,21 @@ static void recv_generator(char *fname, pretend_missing: /* pretend the file didn't exist */ if (preserve_hard_links && file->link_u.links @@ -2004,7 +2004,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. } if (!(back_file = make_file(fname, NULL, NULL, 0, NO_FILTERS))) { close(fd); -@@ -1251,7 +1324,7 @@ static void recv_generator(char *fname, +@@ -1263,7 +1336,7 @@ static void recv_generator(char *fname, full_fname(backupptr)); free(back_file); close(fd); @@ -2013,7 +2013,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. } if ((f_copy = do_open(backupptr, O_WRONLY | O_CREAT | O_TRUNC | O_EXCL, 0600)) < 0) { -@@ -1259,14 +1332,14 @@ static void recv_generator(char *fname, +@@ -1271,14 +1344,14 @@ static void recv_generator(char *fname, full_fname(backupptr)); free(back_file); close(fd); @@ -2030,7 +2030,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. } if (verbose > 2) -@@ -1284,24 +1357,32 @@ static void recv_generator(char *fname, +@@ -1296,24 +1369,32 @@ static void recv_generator(char *fname, iflags |= ITEM_BASIS_TYPE_FOLLOWS; if (fnamecmp_type == FNAMECMP_FUZZY) iflags |= ITEM_XNAME_FOLLOWS; @@ -2068,7 +2068,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. if (f_copy >= 0) { close(f_copy); -@@ -1314,6 +1395,13 @@ static void recv_generator(char *fname, +@@ -1326,6 +1407,13 @@ static void recv_generator(char *fname, } close(fd); @@ -2082,7 +2082,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. } void generate_files(int f_out, struct file_list *flist, char *local_name) -@@ -1373,6 +1461,8 @@ void generate_files(int f_out, struct fi +@@ -1385,6 +1473,8 @@ void generate_files(int f_out, struct fi * notice that and let us know via the redo pipe (or its closing). */ ignore_timeout = 1; @@ -5505,7 +5505,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. +int sys_acl_free_qualifier(void *qual, SMB_ACL_TAG_T tagtype); --- old/log.c +++ new/log.c -@@ -594,8 +594,10 @@ static void log_formatted(enum logcode c +@@ -582,8 +582,10 @@ static void log_formatted(enum logcode c n[5] = !(iflags & ITEM_REPORT_PERMS) ? '.' : 'p'; n[6] = !(iflags & ITEM_REPORT_OWNER) ? '.' : 'o'; n[7] = !(iflags & ITEM_REPORT_GROUP) ? '.' : 'g'; @@ -5570,7 +5570,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. /* Note that this field may not have type ino_t. It depends * on the complicated interaction between largefile feature -@@ -278,7 +284,7 @@ void usage(enum logcode F) +@@ -282,7 +288,7 @@ void usage(enum logcode F) rprintf(F," -v, --verbose increase verbosity\n"); rprintf(F," -q, --quiet suppress non-error messages\n"); rprintf(F," -c, --checksum skip based on checksum, not mod-time & size\n"); @@ -5579,7 +5579,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. rprintf(F," --no-OPTION turn off an implied OPTION (e.g. --no-D)\n"); rprintf(F," -r, --recursive recurse into directories\n"); rprintf(F," -R, --relative use relative path names\n"); -@@ -299,6 +305,9 @@ void usage(enum logcode F) +@@ -303,6 +309,9 @@ void usage(enum logcode F) rprintf(F," -H, --hard-links preserve hard links\n"); rprintf(F," -p, --perms preserve permissions\n"); rprintf(F," -E, --executability preserve the file's executability\n"); @@ -5589,7 +5589,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. rprintf(F," --chmod=CHMOD change destination permissions\n"); rprintf(F," -o, --owner preserve owner (super-user only)\n"); rprintf(F," -g, --group preserve group\n"); -@@ -416,6 +425,9 @@ static struct poptOption long_options[] +@@ -421,6 +430,9 @@ static struct poptOption long_options[] {"no-perms", 0, POPT_ARG_VAL, &preserve_perms, 0, 0, 0 }, {"no-p", 0, POPT_ARG_VAL, &preserve_perms, 0, 0, 0 }, {"executability", 'E', POPT_ARG_NONE, &preserve_executability, 0, 0, 0 }, @@ -5599,7 +5599,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. {"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 }, -@@ -1076,6 +1088,24 @@ int parse_arguments(int *argc, const cha +@@ -1083,6 +1095,24 @@ int parse_arguments(int *argc, const cha usage(FINFO); exit_cleanup(0); @@ -5624,7 +5624,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. default: /* A large opt value means that set_refuse_options() * turned this option off. */ -@@ -1521,6 +1551,10 @@ void server_options(char **args,int *arg +@@ -1528,6 +1558,10 @@ void server_options(char **args,int *arg if (preserve_hard_links) argstr[x++] = 'H'; @@ -5676,15 +5676,15 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. /* We now check to see if we are writing file "inplace" */ --- old/rsync.c +++ new/rsync.c -@@ -33,6 +33,7 @@ +@@ -32,6 +32,7 @@ + extern int verbose; extern int dry_run; - extern int logfile_format_has_i; +extern int preserve_acls; extern int preserve_perms; extern int preserve_executability; extern int preserve_times; -@@ -101,7 +102,8 @@ void free_sums(struct sum_struct *s) +@@ -100,7 +101,8 @@ void free_sums(struct sum_struct *s) /* This is only called when we aren't preserving permissions. Figure out what * the permissions should be and return them merged back into the mode. */ @@ -5694,7 +5694,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. { /* If the file already exists, we'll return the local permissions, * possibly tweaked by the --executability option. */ -@@ -116,55 +118,63 @@ mode_t dest_mode(mode_t flist_mode, mode +@@ -115,55 +117,63 @@ mode_t dest_mode(mode_t flist_mode, mode cur_mode |= (cur_mode & 0444) >> 2; } } else @@ -5772,7 +5772,7 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. ; else #endif -@@ -174,43 +184,55 @@ int set_file_attrs(char *fname, struct f +@@ -173,43 +183,55 @@ int set_file_attrs(char *fname, struct f rprintf(FINFO, "set uid of %s from %ld to %ld\n", fname, @@ -5839,9 +5839,9 @@ latest ACL-enabling patch to send files to an older ACL-enabled rsync. } if (ret == 0) /* ret == 1 if symlink could not be set */ updated = 1; -@@ -224,6 +246,11 @@ int set_file_attrs(char *fname, struct f +@@ -222,6 +244,11 @@ int set_file_attrs(char *fname, struct f else - rprintf(code, "%s is uptodate\n", fname); + rprintf(FCLIENT, "%s is uptodate\n", fname); } + cleanup: +#ifdef SUPPORT_ACLS diff --git a/early-checksum.diff b/early-checksum.diff index c16aa57..fad536f 100644 --- a/early-checksum.diff +++ b/early-checksum.diff @@ -18,7 +18,7 @@ for a local copy, so the old algorithm is used for local copies. extern int module_id; extern int ignore_errors; extern int numeric_ids; -@@ -692,6 +693,16 @@ static struct file_struct *receive_file_ +@@ -691,6 +692,16 @@ static struct file_struct *receive_file_ sum = empty_sum; } read_buf(f, sum, checksum_len); @@ -37,7 +37,7 @@ for a local copy, so the old algorithm is used for local copies. return file; --- old/generator.c +++ new/generator.c -@@ -71,6 +71,7 @@ extern int ignore_timeout; +@@ -70,6 +70,7 @@ extern int ignore_timeout; extern int protocol_version; extern int fuzzy_basis; extern int always_checksum; @@ -45,7 +45,7 @@ for a local copy, so the old algorithm is used for local copies. extern int checksum_len; extern char *partial_dir; extern char *basis_dir[]; -@@ -374,7 +375,8 @@ void itemize(struct file_struct *file, i +@@ -375,7 +376,8 @@ void itemize(struct file_struct *file, i /* Perform our quick-check heuristic for determining if a file is unchanged. */ @@ -55,7 +55,7 @@ for a local copy, so the old algorithm is used for local copies. { if (st->st_size != file->length) return 0; -@@ -383,6 +385,8 @@ int unchanged_file(char *fn, struct file +@@ -384,6 +386,8 @@ int unchanged_file(char *fn, struct file of the file time to determine whether to sync */ if (always_checksum && S_ISREG(st->st_mode)) { char sum[MD4_SUM_LENGTH]; @@ -73,7 +73,7 @@ for a local copy, so the old algorithm is used for local copies. continue; best_match = j; match_level = 2; -@@ -1194,7 +1198,7 @@ static void recv_generator(char *fname, +@@ -1201,7 +1205,7 @@ static void recv_generator(char *fname, ; else if (fnamecmp_type == FNAMECMP_FUZZY) ; @@ -113,7 +113,7 @@ for a local copy, so the old algorithm is used for local copies. int local_server = 0; mode_t orig_umask = 0; struct file_list *the_file_list; -@@ -749,6 +753,7 @@ static void do_server_recv(int f_in, int +@@ -751,6 +755,7 @@ static void do_server_recv(int f_in, int struct file_list *flist; char *local_name = NULL; char *dir = NULL; @@ -121,7 +121,7 @@ for a local copy, so the old algorithm is used for local copies. int save_verbose = verbose; if (filesfrom_fd >= 0) { -@@ -792,6 +797,10 @@ static void do_server_recv(int f_in, int +@@ -794,6 +799,10 @@ static void do_server_recv(int f_in, int filesfrom_fd = -1; } @@ -132,7 +132,7 @@ for a local copy, so the old algorithm is used for local copies. flist = recv_file_list(f_in); verbose = save_verbose; if (!flist) { -@@ -800,6 +809,9 @@ static void do_server_recv(int f_in, int +@@ -802,6 +811,9 @@ static void do_server_recv(int f_in, int } the_file_list = flist; @@ -142,7 +142,7 @@ for a local copy, so the old algorithm is used for local copies. if (argc > 0) local_name = get_local_name(flist,argv[0]); -@@ -883,6 +895,7 @@ int client_run(int f_in, int f_out, pid_ +@@ -885,6 +897,7 @@ int client_run(int f_in, int f_out, pid_ { struct file_list *flist = NULL; int exit_code = 0, exit_code2 = 0; @@ -150,7 +150,7 @@ for a local copy, so the old algorithm is used for local copies. char *local_name = NULL; cleanup_child_pid = pid; -@@ -957,11 +970,18 @@ int client_run(int f_in, int f_out, pid_ +@@ -959,11 +972,18 @@ int client_run(int f_in, int f_out, pid_ filesfrom_fd = -1; } @@ -171,11 +171,11 @@ for a local copy, so the old algorithm is used for local copies. --- old/rsync.h +++ new/rsync.h -@@ -64,6 +64,7 @@ - #define FLAG_DEL_HERE (1<<3) /* receiver/generator */ +@@ -65,6 +65,7 @@ #define FLAG_HLINK_TOL (1<<4) /* receiver/generator */ #define FLAG_NO_FUZZY (1<<5) /* generator */ -+#define FLAG_SUM_DIFFERS (1<<6) /* receiver/generator */ + #define FLAG_MISSING (1<<6) /* generator */ ++#define FLAG_SUM_DIFFERS (1<<7) /* receiver/generator */ /* update this if you make incompatible changes */ #define PROTOCOL_VERSION 29 -- 2.34.1