*** work/rsync-3.0.7/options.c.orig 2009-12-22 00:40:41.000000000 +0200 --- work/rsync-3.0.7/options.c 2010-07-09 15:16:22.000000000 +0300 *************** *** 165,170 **** --- 165,171 ---- char *rsync_path = RSYNC_PATH; char *backup_dir = NULL; char backup_dir_buf[MAXPATHLEN]; + long check_point = -1; char *sockopts = NULL; int rsync_port = 0; int compare_dest = 0; *************** *** 325,330 **** --- 326,332 ---- rprintf(F," -b, --backup make backups (see --suffix & --backup-dir)\n"); rprintf(F," --backup-dir=DIR make backups into hierarchy based in DIR\n"); rprintf(F," --suffix=SUFFIX set backup suffix (default %s w/o --backup-dir)\n",BACKUP_SUFFIX); + rprintf(F," --check-point=FILE don't delete files newer than FILE\n"); rprintf(F," -u, --update skip files that are newer on the receiver\n"); rprintf(F," --inplace update destination files in-place (SEE MAN PAGE)\n"); rprintf(F," --append append data onto shorter files\n"); *************** *** 609,614 **** --- 611,617 ---- {"backup", 'b', POPT_ARG_VAL, &make_backups, 1, 0, 0 }, {"no-backup", 0, POPT_ARG_VAL, &make_backups, 0, 0, 0 }, {"backup-dir", 0, POPT_ARG_STRING, &backup_dir, 0, 0, 0 }, + {"check-point", 0, POPT_ARG_INT, &check_point, 0, 0, 0 }, {"suffix", 0, POPT_ARG_STRING, &backup_suffix, 0, 0, 0 }, {"list-only", 0, POPT_ARG_VAL, &list_only, 2, 0, 0 }, {"read-batch", 0, POPT_ARG_STRING, &batch_name, OPT_READ_BATCH, 0, 0 }, *************** *** 1924,1929 **** --- 1927,1938 ---- args[ac++] = backup_dir; } + if (check_point >= 0) { + if (asprintf(&arg, "--check-point=%d", check_point) < 0) + goto oom; + args[ac++] = arg; + } + /* Only send --suffix if it specifies a non-default value. */ if (strcmp(backup_suffix, backup_dir ? "" : BACKUP_SUFFIX) != 0) { /* We use the following syntax to avoid weirdness with '~'. */