Wayne Davison [Mon, 18 Dec 2006 06:56:30 +0000 (06:56 +0000)]
Moved the write_stream_flags() call from io.c into main.c so that
it gets called before the transfer starts (thus ensuring that it
can write out un-tweaked values of preserver_[ug]id vars).
Wayne Davison [Sun, 17 Dec 2006 00:40:28 +0000 (00:40 +0000)]
Got rid of the hlink_pool in favor of using the new hashtable code
on the receiving side. This allows us to always use a 32-bit number
to identify the hardlink clusters, even on a system where pointers
are 64-bits. Also made changes to handle the use of F_ROOTDIR() and
F_DEPTH() instead of the old union that wasted space on the
receiving side when pointers are 64-bits.
Wayne Davison [Sun, 17 Dec 2006 00:40:24 +0000 (00:40 +0000)]
- Got rid of "struct idev".
- Use just the 32-bit numbers in the file_extras union.
- Re-ordered the items in the file_struct to avoid padding
on systems with 64-bit pointers.
- Got rid of the "dir" union in the file_struct, making the
two items into "extras": F_DEPTH() for the receiving side,
and F_ROOTDIR() for the sending side.
- Added PTR_EXTRA_LEN define.
- Got rid of F_HL_IDEV() define.
Wayne Davison [Sat, 16 Dec 2006 19:24:14 +0000 (19:24 +0000)]
Use the new rounding.h file to optionally round up the count of
extra values we put at the start of the file_struct. Also, deal
with the extras variable no longer being in the file_struct.
Wayne Davison [Fri, 15 Dec 2006 22:31:13 +0000 (22:31 +0000)]
Added a simple hashtable routine for hashing st_dev and st_ino info
on the sending side, and the support routines for the receiving side
that handle using a "group number" for each hard-link cluster rather
than having to manage a pool of dev+inode data. (For protocol 30)
Wayne Davison [Fri, 15 Dec 2006 22:31:10 +0000 (22:31 +0000)]
For protocol 30, the sender uses the new idev_node() hashfile
routine to keep track of which item is the first one in a particular
hard-link cluster. It then abbreviates the sending of any follow-on
items in the cluster, reducing transfer bytes. It also omits the
sending of any dev+inode data to the receiver, saving even more xfer
bytes (since the receiver can associate the entries based on the the
group's index number that is sent when abbreviating an entry).
Wayne Davison [Fri, 15 Dec 2006 22:31:07 +0000 (22:31 +0000)]
- The XMIT_SAME_DEV define is now pre-protocol-30 specific.
- Added XMIT_HLINK_FIRST define.
- Added struct idev_node.
- Added F_HL_GNUM() for protocol 30 (used in place of F_HL_IDEV()).
Wayne Davison [Sat, 9 Dec 2006 00:24:08 +0000 (00:24 +0000)]
- Added FLAG_HLINK_DONE.
- Added BITS_SET() and BITS_SETnUNSET() defines.
- Got rid of unused HL_* defines.
- Got rid of no-longer-needed struct hlist.
- Changed F_HL_LIST() to F_HL_PREV().
- Added F_NOT_HLINK_FIRST() and F_NOT_HLINK_LAST().
- Got rid of WITH_HLINK and WITHOUT_HLINK.
- Got rid of the hlink_pool in the file list.
Wayne Davison [Sat, 9 Dec 2006 00:23:55 +0000 (00:23 +0000)]
- Revamped the hard-link algorithm to save memory.
- Improved the function names.
- Improved a few variable names.
- Got rid of the "is a hard link" message in favor of the normal status
messages for files (e.g. --itemize-changes indicates hard-links).
- Fixed a long-standing bug when combining -H with --compare-dest.
- Made sure that code compiles when hard-linking is not available.
Wayne Davison [Fri, 8 Dec 2006 20:42:45 +0000 (20:42 +0000)]
- The --delete-delay code now does its own output buffering. This
allows us to delay opening a temp file to hold the list of deletions
until we overflow the buffer (and thus, it's not usually needed).
- Fall back to doing a --delete-after pass if the --delete-delay
code has a temp-file-writing failure.
Wayne Davison [Thu, 7 Dec 2006 03:31:28 +0000 (03:31 +0000)]
- Added a signed number to the flist_extras union.
- Renamed F_IDEV() to F_HL_IDEV() and F_HLIST() to F_HL_LIST().
- Changed device defines to be: F_RDEV_P(), DEV_MAJOR(), and DEV_MINOR().
Wayne Davison [Wed, 6 Dec 2006 01:26:11 +0000 (01:26 +0000)]
- Make some char* pointers const.
- Tweaked a couple variable names.
- Changed the #ifdefs to not define any hard-link functions
when hard-linking is disabled.