Commit Graph

3379 Commits

Author SHA1 Message Date
Wayne Davison
6087ef2a84 - Changed read_item_attrs() to return the length of the xname string.
- Tweaked the order of the args to write_item_attrs().
2005-03-10 00:05:58 +00:00
Wayne Davison
1f1d368ad5 - Improved the error-checking for some delete_item() calls.
- Move the non-regular-file delete-check above the alt-basis check
  where it belongs.
- Keep track of the real statret and real stat-struct for certain
  alt-basis scenarios (e.g. partial-dir and fuzzy) so that we send
  the right itemized change flags.
2005-03-09 23:46:28 +00:00
Wayne Davison
dd18526e5b Mention the latest protocol-29 changes. 2005-03-09 18:55:09 +00:00
Wayne Davison
4d53c4dd46 We now handle the reading and writing of extra basis-file info: the
fnamecmp_type byte, and the extra name (currently used for fuzzy
processing and hard-link status).
2005-03-09 18:54:19 +00:00
Wayne Davison
9e4a8d29b5 Got rid of the name-pipe, so we now read the fnamecmp_type data over
the socket for protocol >= 29, or handle it like the old days for
older protocol versions.  This means that we now validate this extra
data for safety (such as the fuzzy filename).
2005-03-09 18:54:16 +00:00
Wayne Davison
ef20efcbb6 Made itemize() output the fnamecmp_type and the fuzzy name based on
the new ITEM_BASIS_TYPE_FOLLOWS and ITEM_XNAME_FOLLOWS flags.  Got
rid of the name-pipe to the receiver.
2005-03-09 18:54:12 +00:00
Wayne Davison
c70e07d9ac Got rid of the name-pipe from the generator to the receiver. 2005-03-09 18:54:09 +00:00
Wayne Davison
b7d4d28bb3 When itemizing, we now set ITEM_LOCAL_CHANGE and ITEM_XNAME_FOLLOWS. 2005-03-09 18:54:06 +00:00
Wayne Davison
9a6ed83f2c - Made an overflow in read_vstring() return an error instead of dying.
- Got rid of a flush kluge that was needed for the name-pipe.
2005-03-09 18:54:02 +00:00
Wayne Davison
fd84673e54 Handle the new way that 'c' and 'h' get output by "%i". 2005-03-09 18:53:58 +00:00
Wayne Davison
57b12568e6 Complain if a feature that requires protocol 29 doesn't get it. 2005-03-09 18:53:55 +00:00
Wayne Davison
f9a9f54720 Made the dest_option string non-static. 2005-03-09 18:53:53 +00:00
Wayne Davison
3019a9bafd Changed some of the ITEM_* defines. 2005-03-09 18:53:49 +00:00
Wayne Davison
278e3d4f6e Mention the latest bug-fix. 2005-03-09 04:00:45 +00:00
Wayne Davison
9b9dd06894 We need to mention any change to a directory, not just a time change.
Yeah, this isn't very consistent with how files are treated, but it's
backward compatible.
2005-03-09 04:00:20 +00:00
Wayne Davison
1f7e29b99c Fixed the change-report output for a directory that has no
write permissions.
2005-03-09 03:49:07 +00:00
Wayne Davison
c2f0e6e5e3 Backward compatibility fix in read_iflags() (for protocols < 29). 2005-03-09 02:25:34 +00:00
Wayne Davison
c2b11ba017 Backed out the hack that reversed ITEM_REPORT_XATTRS with
ITEM_TRANSFER.  Yes, it allowed some kludge code that made backward
compatibility seamless, but it made it impossible to remove the hack
in the future.  This way, the backward compatibility is just
slightly inaccurate in the display of the first letter in the %i
output, and the only hack can be safely removed without causing
problems.
2005-03-06 23:37:42 +00:00
Wayne Davison
f75a53e71b - When --max-delete is exceeded, we now count how many deletions
would have happend, warn about the number skipped, and set
  io_error to IOERR_DEL_LIMIT.
- When dry_run > 1 (which indicates that the destinationdir is
  missing), skip deletions in that dir.  This fixes a bug in a
  copy that is creating the destination dir w/--delete enabled.
2005-03-05 18:58:42 +00:00
Wayne Davison
054abde25f Handle new IOERR_DEL_LIMIT bit in io_error. 2005-03-05 18:58:38 +00:00
Wayne Davison
24cecf1365 Define the message for RERR_DEL_LIMIT. 2005-03-05 18:58:35 +00:00
Wayne Davison
821ff7f49a Added RERR_DEL_LIMIT. 2005-03-05 18:58:32 +00:00
Wayne Davison
ff3d3c32d5 Added IOERR_DEL_LIMIT. 2005-03-05 18:58:29 +00:00
Wayne Davison
3b2ef5b11c Mention that --max-delete must be non-zero. 2005-03-05 18:58:26 +00:00
Wayne Davison
0394e34a69 Moved the end_progress() call from match.c to sender.c so that we
report progress on 0-length files when pushing files (the receiver
already called it, so we already produced progress on a 0-length
file when pulling).
2005-03-05 17:51:23 +00:00
Wayne Davison
56efa56474 Fixed the elapsed time reported for 0-length files. 2005-03-05 17:49:46 +00:00
Wayne Davison
ed7e79553e Don't try to determine the phase we're in by looking at the value
of csum_length -- it might have been computed to be SUM_LENGTH.
Instead, look at the "phase" variable directly.
2005-03-05 16:42:52 +00:00
Wayne Davison
dec71e94f3 Added a hack that uses the ITEM_REPORT_XATTRS bit (which is the old
ITEM_UPDATING bit) to make us compatible when sending/receiving bits
to/from an earlier pre-release.
2005-03-05 04:34:06 +00:00
Wayne Davison
ac4f91a5ee Added a hack that sets the ITEM_REPORT_XATTRS bit (which is the old
ITEM_UPDATING bit) when ITEM_TRANSFER or ITEM_LOCAL_CHANGE is set.
This lets us interact compatibly when sending itemized bits to an
earlier pre-release.
2005-03-05 04:34:04 +00:00
Wayne Davison
e957626347 Swapped the bit-values for ITEM_TRANSFER and ITEM_REPORT_XATTRS.
This lets us be more compatible with the earlier pre-releases
with a better heuristic for backward-compatible itemized bits.
2005-03-05 04:34:01 +00:00
Wayne Davison
b4875de45c Improved the description of when "h" is output by %i. 2005-03-05 00:34:02 +00:00
Wayne Davison
2cfe44eee4 Turned on -i for itemized output. 2005-03-05 00:23:55 +00:00
Wayne Davison
fad3dc421c - Updated to handle the new ITEM_* flags.
- Changed read_iflags() to read/write a suffixed hard-link name.
2005-03-05 00:21:59 +00:00
Wayne Davison
22907b6bd9 - Updated to handle the new ITEM_* flags.
- Send MSG_SUCCESS for hard-linked files when -H was specified.
2005-03-05 00:21:56 +00:00
Wayne Davison
3485ae8321 A few minor tweaks to improve two error messages and make better use
of the "the_file_list" global.
2005-03-05 00:21:54 +00:00
Wayne Davison
ca62acc3ca - Make use of the new ITEM_* flags to mention when things were
updated locally instead of being updated remotely.
- Added support for outputting 'a' in the itemized log-output (for
  future use in extended-attribute handling).
2005-03-05 00:21:50 +00:00
Wayne Davison
cdf236aaf5 - Made the sock_{in,out} variables non-static.
- Added hlink_list, a FIFO list of finished hard-link items.
- Made get_redo_num() check for finished hard-link items and
  call the generator when they are found.  This ensures that
  we finish all the hard-link items by the time the MSG_DONE
  is read and returned to the generator.
- Added get_hlink_num() to read the new hlink_list.
2005-03-05 00:21:48 +00:00
Wayne Davison
9f2e3c3f52 - Changed hlink_list[] to store file-list indexes instead of
pointers.
- Made hard_link_one() non-static so that the generator can call it.
  Improved it to do itemized output.
- Replaced do_hard_links() with hard_link_cluster(), which changes
  the hard-linking from a post-transfer loop into a per-cluster
  operation that occurs incrementally as the transfer updates (or
  finds unchanged) one item in the cluster.
2005-03-05 00:21:44 +00:00
Wayne Davison
ee1d11c495 - Updated itemize() to handle sending of hard-link-name info. Made
it non-static so the hard-link code can now output itemized
  messages.
- Made the locally-changed items (such as dirs and symlinks) itemize
  using a new ITEM_LOCAL_CHANGE flag instead of the (renamed)
  ITEM_TRANSFER flag (formerly ITEM_UPDATING).
- Improved the hard-link support by having a cluster of hard-linked
  files get processed as soon as we notice that a single item is
  already up-to-date, or it succssfully finishes being updated.
- The hard-linking that occurs when using --link-dest will now be
  mentioned at higher levels of verbosity IFF %i is in the log-
  format.
2005-03-05 00:21:42 +00:00
Wayne Davison
669e76717c - Changed ITEM_UPDATING to ITEM_TRANSFER.
- Added defines ITEM_HARD_LINKED, ITEM_LOCAL_CHANGE,
  ITEM_REPORT_XATTRS, and SIGNIFICANT_ITEM_FLAGS.
- Changed the "next" var in struct hlink into an int.
2005-03-05 00:21:39 +00:00
Wayne Davison
4e107712f3 Mention latest bug fixes. 2005-03-05 00:20:37 +00:00
Wayne Davison
85aa57a7dd In read_iflags(), we need to set buf to an empty string. 2005-03-04 18:01:16 +00:00
Wayne Davison
58a14ed950 Got rid of some code in the main recv_files() loop by calling the
new functions read_iflags() and maybe_log_item().
2005-03-04 16:54:08 +00:00
Wayne Davison
165e6d446c Moved some code out of the main loop in send_files() into a new
function called read_iflags() (which was made generic enough that
the receiver could use it too).  Also call the new maybe_log_item().
2005-03-04 16:53:26 +00:00
Wayne Davison
1c3e3679ef Added maybe_log_item() for use by the sender and receiver. 2005-03-04 16:52:00 +00:00
Wayne Davison
8a513e55b0 Document the new value of %L. 2005-03-04 16:11:09 +00:00
Wayne Davison
a314f7c155 Document latest format of %i. 2005-03-04 16:08:58 +00:00
Wayne Davison
9497b0d4e9 Call log_item() instead of log_recv(). 2005-03-04 16:08:16 +00:00
Wayne Davison
b694f8a245 Call log_item() instead of log_send(). 2005-03-04 16:08:02 +00:00
Wayne Davison
afc65a5acf - Replaced log_send() and log_recv() with log_item().
- Made log_formatted() and log_item() take an "hlink" arg that
  will be used to pass in a hard-link name for use in %L.
2005-03-04 16:07:50 +00:00