make proto
---- orig/Makefile.in 2004-08-09 21:07:09
+--- orig/Makefile.in 2004-08-13 07:18:58
+++ Makefile.in 2004-07-03 20:13:41
@@ -34,7 +34,7 @@ ZLIBOBJ=zlib/deflate.o zlib/infblock.o z
OBJS1=rsync.o generator.o receiver.o cleanup.o sender.o exclude.o util.o \
+ }
+ return 0;
+}
---- orig/flist.c 2004-08-11 23:42:23
+--- orig/flist.c 2004-08-12 18:34:38
+++ flist.c 2004-07-03 20:13:41
@@ -33,6 +33,7 @@ extern int verbose;
extern int do_progress;
file->uid = st.st_uid;
file->gid = st.st_gid;
---- orig/options.c 2004-08-11 23:42:23
+--- orig/options.c 2004-08-12 18:34:38
+++ options.c 2004-07-03 20:13:41
@@ -126,6 +126,7 @@ char *log_format = NULL;
char *password_file = NULL;
if (files_from && (!am_sender || remote_filesfrom_file)) {
if (remote_filesfrom_file) {
args[ac++] = "--files-from";
---- orig/rsync.yo 2004-08-11 17:26:27
+--- orig/rsync.yo 2004-08-13 07:18:59
+++ rsync.yo 2004-07-03 20:13:41
-@@ -301,6 +301,7 @@ verb(
+@@ -330,6 +330,7 @@ verb(
-g, --group preserve group
-D, --devices preserve devices (root only)
-t, --times preserve times
-S, --sparse handle sparse files efficiently
-n, --dry-run show what would have been transferred
-W, --whole-file copy whole files, no incremental checks
-@@ -574,6 +575,14 @@ cause the next transfer to behave as if
+@@ -603,6 +604,14 @@ cause the next transfer to behave as if
updated (though the rsync algorithm will make the update fairly efficient
if the files haven't actually changed, you're much better off using -t).
if (st->st_size != file->length)
return 0;
if (link_dest) {
---- orig/options.c 2004-08-11 23:42:23
+--- orig/options.c 2004-08-12 18:34:38
+++ options.c 2004-07-03 20:16:51
@@ -84,6 +84,7 @@ int keep_partial = 0;
int safe_symlinks = 0;
if (modify_window_set) {
if (asprintf(&arg, "--modify-window=%d", modify_window) < 0)
goto oom;
---- orig/rsync.yo 2004-08-11 17:26:27
+--- orig/rsync.yo 2004-08-13 07:18:59
+++ rsync.yo 2004-07-03 20:16:51
-@@ -323,6 +323,7 @@ verb(
+@@ -352,6 +352,7 @@ verb(
--timeout=TIME set I/O timeout in seconds
-I, --ignore-times turn off mod time & file size quick check
--size-only ignore mod time for quick check (use size)
--modify-window=NUM compare mod times with reduced accuracy
-T --temp-dir=DIR create temporary files in directory DIR
--compare-dest=DIR also compare received files relative to DIR
-@@ -397,6 +398,12 @@ regardless of timestamp. This is useful
+@@ -426,6 +427,12 @@ regardless of timestamp. This is useful
after using another mirroring system which may not preserve timestamps
exactly.
Note that you'll need to run 'make proto' after applying this patch.
---- orig/Makefile.in 2004-08-09 21:07:09
+--- orig/Makefile.in 2004-08-13 07:18:58
+++ Makefile.in 2004-07-03 20:18:02
@@ -35,7 +35,7 @@ OBJS1=rsync.o generator.o receiver.o cle
main.o checksum.o match.o syscall.o log.o backup.o
+
+ return result;
+}
---- orig/util.c 2004-08-12 18:34:39
+--- orig/util.c 2004-08-13 07:18:59
+++ util.c 2004-07-03 20:18:02
-@@ -1219,3 +1219,55 @@ void *_realloc_array(void *ptr, unsigned
+@@ -1217,3 +1217,55 @@ void *_realloc_array(void *ptr, unsigned
return malloc(size * num);
return realloc(ptr, size * num);
}
This patch from Sami Farin lets you specify --fsync if you want fsync()
to be called on every file we write.
---- orig/options.c 2004-08-11 23:42:23
+--- orig/options.c 2004-08-12 18:34:38
+++ options.c 2004-07-03 20:18:13
@@ -38,6 +38,7 @@ int make_backups = 0;
**/
exit_cleanup(RERR_FILEIO);
}
-+ if (do_fsync && (fd != -1) && (fsync(fd) != 0)) {
++ if (do_fsync && fd != -1 && fsync(fd) != 0) {
+ rsyserr(FERROR, errno, "fsync failed on %s",
+ full_fname(fname));
+ exit_cleanup(RERR_FILEIO);
sum_end(file_sum1);
if (mapbuf)
---- orig/util.c 2004-08-11 23:42:23
+--- orig/util.c 2004-08-13 07:18:59
+++ util.c 2004-07-03 20:18:13
@@ -33,6 +33,7 @@ extern int module_id;
extern int modify_window;
/* The receiving side mustn't obey this, or an existing symlink that
* points to an identical file won't be replaced by the referent. */
---- orig/options.c 2004-08-11 23:42:23
+--- orig/options.c 2004-08-12 18:34:38
+++ options.c 2004-07-16 20:14:12
@@ -85,6 +85,7 @@ int safe_symlinks = 0;
int copy_unsafe_links = 0;
/* Log-message categories. FLOG is only used on the daemon side to
---- orig/rsync.yo 2004-08-11 17:26:27
+--- orig/rsync.yo 2004-08-13 07:18:59
+++ rsync.yo 2004-07-03 19:27:25
-@@ -327,6 +327,7 @@ verb(
+@@ -356,6 +356,7 @@ verb(
-T --temp-dir=DIR create temporary files in directory DIR
--compare-dest=DIR also compare received files relative to DIR
--link-dest=DIR create hardlinks to DIR for unchanged files
handle relative symlinks properly, and that has not yet been fixed
in this modified version.
---- orig/flist.c 2004-08-11 23:42:23
+--- orig/flist.c 2004-08-12 18:34:38
+++ flist.c 2004-07-16 16:58:04
@@ -49,6 +49,7 @@ extern int filesfrom_fd;
extern int one_file_system;
#else
linkname_len = 0;
#endif
---- orig/options.c 2004-08-11 23:42:23
+--- orig/options.c 2004-08-12 18:34:38
+++ options.c 2004-07-16 16:12:29
@@ -42,6 +42,7 @@ int archive_mode = 0;
int keep_dirlinks = 0;
}
if (preserve_links && S_ISLNK(file->mode)) {
---- orig/options.c 2004-08-11 23:42:23
-+++ options.c 2004-07-15 02:34:44
+--- orig/options.c 2004-08-12 18:34:38
++++ options.c 2004-08-13 18:26:04
@@ -90,6 +90,7 @@ int delete_after = 0;
int only_existing = 0;
int opt_ignore_existing = 0;
{"timeout", 0, POPT_ARG_INT, &io_timeout, OPT_TIMEOUT, 0, 0 },
{"temp-dir", 'T', POPT_ARG_STRING, &tmpdir, 0, 0, 0 },
{"compare-dest", 0, POPT_ARG_STRING, &compare_dest, 0, 0, 0 },
-@@ -604,6 +608,32 @@ int parse_arguments(int *argc, const cha
+@@ -604,6 +608,33 @@ int parse_arguments(int *argc, const cha
read_batch = 1;
break;
+ break;
+ default:
+ rprintf(FERROR,
-+ "--max-size value is invalid.\n");
++ "--max-size value is invalid: %s\n",
++ max_size_arg);
+ exit_cleanup(RERR_SYNTAX);
+ break;
+ }
case OPT_TIMEOUT:
if (io_timeout && io_timeout < select_timeout)
select_timeout = io_timeout;
-@@ -983,6 +1013,11 @@ void server_options(char **args,int *arg
+@@ -983,6 +1014,11 @@ void server_options(char **args,int *arg
args[ac++] = arg;
}
if (io_timeout) {
if (asprintf(&arg, "--timeout=%d", io_timeout) < 0)
goto oom;
---- orig/rsync.yo 2004-08-11 17:26:27
+--- orig/rsync.yo 2004-08-13 07:18:59
+++ rsync.yo 2004-07-03 20:20:46
-@@ -316,6 +316,7 @@ verb(
+@@ -345,6 +345,7 @@ verb(
--delete-after receiver deletes after transfer, not before
--ignore-errors delete even if there are I/O errors
--max-delete=NUM don't delete more than NUM files
--partial keep partially transferred files
--partial-dir=DIR put a partially transferred file into DIR
--force force deletion of dirs even if not empty
-@@ -599,6 +600,11 @@ dit(bf(--max-delete=NUM)) This tells rsy
+@@ -628,6 +629,11 @@ dit(bf(--max-delete=NUM)) This tells rsy
files or directories. This is useful when mirroring very large trees
to prevent disasters.
if (!am_server && !am_daemon) {
rprintf(FERROR, "io timeout after %d seconds - exiting\n",
(int)(t-last_io));
---- orig/options.c 2004-08-11 23:42:23
+--- orig/options.c 2004-08-12 18:34:38
+++ options.c 2004-07-15 17:06:09
@@ -96,6 +96,7 @@ int blocking_io = -1;
int checksum_seed = 0;
if (backup_dir) {
args[ac++] = "--backup-dir";
args[ac++] = backup_dir;
---- orig/rsync.yo 2004-08-11 17:26:27
+--- orig/rsync.yo 2004-08-13 07:18:59
+++ rsync.yo 2004-07-15 02:44:40
-@@ -349,6 +349,8 @@ verb(
+@@ -378,6 +378,8 @@ verb(
--log-format=FORMAT log file transfers using specified format
--password-file=FILE get password from FILE
--bwlimit=KBPS limit I/O bandwidth, KBytes per second
--write-batch=FILE write a batch to FILE
--read-batch=FILE read a batch from FILE
--checksum-seed=NUM set block/file checksum seed
-@@ -943,6 +945,19 @@ transfer was too fast, it will wait befo
+@@ -972,6 +974,19 @@ transfer was too fast, it will wait befo
result is an average transfer rate equaling the specified limit. A value
of zero specifies no limit.
dit(bf(--write-batch=FILE)) Record a file that can later be applied to
another identical destination with --read-batch. See the "BATCH MODE"
section for details.
---- orig/util.c 2004-08-11 23:42:23
+--- orig/util.c 2004-08-13 07:18:59
+++ util.c 2004-07-03 20:23:22
@@ -126,6 +126,132 @@ void overflow(char *str)
exit_cleanup(RERR_MALLOC);