Wayne Davison [Fri, 25 Feb 2005 21:58:13 +0000 (21:58 +0000)]
- Added variable "ignore_timeout" that lets the generator tell
us to ignore a timeout without turning off the timeout-related
time-keeping that the keep-alive processing needs.
- Added a new function: maybe_send_keepalive().
Wayne Davison [Fri, 25 Feb 2005 17:08:31 +0000 (17:08 +0000)]
Got rid of kluged value for am_sender, and instead added a new
variable named am_starting_up that is non-zero during the option
parsing. This lets the who_am_i() routine output a better value
for debugging info that is output during the option parsing.
Wayne Davison [Wed, 23 Feb 2005 02:56:42 +0000 (02:56 +0000)]
- Fixed a problem with full_fname() when curr_dir was "/".
- Made full_fname() consistently output a leading "/" for
module paths no matter if chroot is in use or not.
Wayne Davison [Tue, 22 Feb 2005 21:43:59 +0000 (21:43 +0000)]
We now look for the ITEM_USING_ALT_BASIS flag for an --inplace
transer that is using an alternate basis file (instead of reading
an extra byte after the flag word).
Wayne Davison [Tue, 22 Feb 2005 21:43:57 +0000 (21:43 +0000)]
We now set the ITEM_USING_ALT_BASIS flag for an --inplace transfer
that is using an alternate basis file (instead of sending an extra
byte after the flag word).
Wayne Davison [Tue, 22 Feb 2005 03:16:41 +0000 (03:16 +0000)]
- Iterate through the deletion list in reverse order so that we
can't delete a backup file that we just created.
- The rename-directory-for-backup heuristic now checks the
DEL_FORCE_RECURSE flag, not the zap_dir variable. We also set
the flag when we recurse so that only the root dir of a deleted
hierarchy can be missing the flag (and thus be a call from the
generator).
Wayne Davison [Tue, 22 Feb 2005 00:42:12 +0000 (00:42 +0000)]
A couple changes in delete_file() make us more compatible with
older versions: (1) we no longer complain if excluded files
sticking around cause us to not be able to remove a subdir, and
(2) we output the name of the removed subdir after it has been
successfully removed.
Wayne Davison [Mon, 21 Feb 2005 10:50:32 +0000 (10:50 +0000)]
- Moved delete_file() into flist.c.
- No need to separately test for (make_backups && !backup_dir)
because omit_dir_times is now set under those circumstances.
Wayne Davison [Mon, 21 Feb 2005 10:50:30 +0000 (10:50 +0000)]
- Moved delete_file() here from rsync.c and improved it to avoid
removing files we just backed up to the current directory and to
rename a non-empty dir to dir~ (when no backup-dir is specified).
- Made delete_missing() static.
Wayne Davison [Mon, 21 Feb 2005 10:03:23 +0000 (10:03 +0000)]
- Set omit_dir_times if backing up files w/o a backup dir.
- Only send an explicitly specified -O (--omit-dir-times)
if it won't be inferred by the receiver.
Wayne Davison [Sun, 20 Feb 2005 20:55:24 +0000 (20:55 +0000)]
Changed the memory implementation of --delay-updates so that it
only allocates memory to store needed bits, it sparsely allocates
the bits in 16KB chunks, and the bit-finding loop works in a more
efficient manner.
Wayne Davison [Sun, 20 Feb 2005 01:04:54 +0000 (01:04 +0000)]
- For every file that we send off to the receiver, mark it with
FLAG_SENT.
- Added successful_send(), which is called when MSG_SUCCESS was
received from the receiver/generator side. This function
validates the message, and removes the indicated file/symlink
(assuming that remove_sent_files was actually set).
Wayne Davison [Sun, 20 Feb 2005 01:04:49 +0000 (01:04 +0000)]
- If --remove-sent-files was specified, abort if we're pulling from
a read-only module.
- If need_messages_from_generator is set, make sure that the
connection between the generator to the sender has multiplexed
I/O enabled.
Wayne Davison [Sat, 19 Feb 2005 23:41:52 +0000 (23:41 +0000)]
- Needed to use a name buffer in delete_missing() to avoid having
a recursive delete reuse our buffer from f_name().
- Moved the backup-handling into delete_file() in rsync.c.
- Moved the --max-delete counting into delete_file() in rsync.c.
Wayne Davison [Sat, 19 Feb 2005 22:16:53 +0000 (22:16 +0000)]
When logging PERMS_REPORT messages, send them with the FCLIENT code
if the daemon has "%i" in its log message (because it already got a
detailed log message from the generator).
Wayne Davison [Sat, 19 Feb 2005 22:16:50 +0000 (22:16 +0000)]
- Always send the itemized-info bytes on to the receiver. This
not only ensures that batch files are created consistently for
push and pull, but allows a daemon to log itemized changes.
- Improved the logging of itemized changes for the daemon.
- Make sure we debug-log our presence in send_files().
Wayne Davison [Sat, 19 Feb 2005 22:16:45 +0000 (22:16 +0000)]
Make use of new variables (log_format_has_i, log_format_has_o_or_i,
and daemon_log_format_has_i) and the new FCLIENT logging code to
output stats in the best way possible for both the client and the
daemon.
Wayne Davison [Sat, 19 Feb 2005 22:16:41 +0000 (22:16 +0000)]
The FCLIENT log code aviods putting the message into the daemon's
log file and instead sends a FINFO message to the client. This is
used when the daemon wants to log a better message locally than it
is sending to the client. Improved log_delete() to make use of this
idiom if it needs to log a separate delete message for the daemon
and the client.
Wayne Davison [Sat, 19 Feb 2005 22:16:39 +0000 (22:16 +0000)]
- Added log_format_has_i.
- Fixed a problem withe option-refusing code when it refuses the
daemon options.
- Don't sent --itemize-changes (-i) to the server -- send an
improved --log-format value instead.
Wayne Davison [Sat, 19 Feb 2005 19:36:54 +0000 (19:36 +0000)]
We now use a regular expression to parse the (restored to its previous
version) default logfile format. Added parsing for a version of the
default logfile format where %o has been replaced with %i.
Wayne Davison [Sat, 19 Feb 2005 03:54:11 +0000 (03:54 +0000)]
- Set new variable, log_format_has_o_or_i.
- Make sure that -i can't be set w/o an actual %i in the log_format.
- Only need to pass -i to server if we're the sender.
- Only need to pass some --log-format information to the server in
certain circumstances.
Wayne Davison [Sat, 19 Feb 2005 03:12:21 +0000 (03:12 +0000)]
Rules read in from per-dir merge files need to have non-applicable
rules filtered out before the rule gets stored (not in a post-
filtering pass like the rules that are read-in prior to the run).
Wayne Davison [Sat, 19 Feb 2005 02:39:30 +0000 (02:39 +0000)]
Notify the remote side about -i (if either specified or inferred from
the user's --log-format string) and, if we're not verbose but we're
logging messages, let the server know that --log-format was specified.