Commit Graph

269 Commits

Author SHA1 Message Date
Matt McCutchen
42560e2e53 Give a meaningful error message when we fail to write to a batch file. 2009-03-13 09:46:39 -07:00
Wayne Davison
445640e803 Update the copyright year. 2009-01-17 13:41:35 -08:00
Wayne Davison
c6c339cd18 Avoid a potential hang when --remove-*-files is active. 2008-11-09 18:02:11 -08:00
Wayne Davison
7c573428a9 Fixed skipping of unneeded updates in a batch file when incremental
recursion is active.  Added a test for this.  Made batch-mode handle
redos properly (and without hanging).
2008-09-26 21:32:43 -07:00
Wayne Davison
f7e65c7b61 Moved the flist_ndx_{push,pop}() routines from io.c into util.c. 2008-09-26 21:21:52 -07:00
Wayne Davison
deea1f70bd Got rid of the check_for_io_err code, as it could cause a hang.
The io_error issue will be fixed in a better way in 3.1.0.
2008-08-31 09:51:29 -07:00
Wayne Davison
a91e678324 Some minor improvements to the flushing code to try to make it
even more solid.
2008-08-24 13:39:44 -07:00
Wayne Davison
9bed85542c Changed flist_for_ndx() to optionally die with an error
if the index isn't found.
2008-08-14 07:32:18 -07:00
Wayne Davison
fc088e30c8 When using --iconv, if a server-side receiver can't convert a filename,
it now outputs the name back to the client without mangling the charset.
2008-08-02 10:25:17 -07:00
Wayne Davison
7790ee3684 Added logic to the receiving side to ensure that the --delete-during
code will not delete in a directory prior to receiving an I/O error
for that directory (or not receiving it, as the case may be).
2008-08-02 09:03:49 -07:00
Wayne Davison
8bd77e7098 Fixed the sending of large files with older rsync versions by
handling the old block-size limit for protocols < 29.
2008-06-23 09:17:55 -07:00
Wayne Davison
73cb6738b3 Improved --dirs/--no-dirs/--list-only option handling:
- Moved setting of list_only and xfer_dirs from main.c to options.c.
- Fixed the ability of the user to force --no-dirs.
- Added the --old-dirs/--old-d option to make it easier to interact
  in list-only mode with an older rsync.
- Suggest the use of --old-d instead of "-r --exclude='/*/*'".
2008-03-24 09:54:04 -07:00
Wayne Davison
987a546756 A couple improvements to the new arg-globbing code:
- Put all the state variables into a single struct.
- Reuse the buffer memory for each glob_expand() call until a final
  call with a NULL pointer tells us to free it.
2008-03-21 07:22:34 -07:00
Wayne Davison
53936ef935 Fixed the use of --protect-args (-s) with a daemon. 2008-03-15 11:56:18 -07:00
Wayne Davison
7f9bf6b710 Generate a helpful message when we get an option-error from a daemon
while requesting a file-listing and we suspect that the remote rsync
is complaining about the -d option.
2008-03-15 11:24:38 -07:00
Wayne Davison
d3d07a5e86 Include 2008 in the copyright years. 2008-03-01 12:01:41 -08:00
Wayne Davison
3f0211b63a New logging categories added to allow differentiation between
transfer errors, normal errors, and warnings.  New messages are
translated into old FERROR/FINFO categories for older protocols.
2007-11-22 10:05:36 -08:00
Wayne Davison
ee6e80c753 Fix two iconv problems that Lennart Lövstrand pointed out in bug 5075. 2007-11-22 07:57:03 -08:00
Wayne Davison
17a4977bef In mplex_write(), make extra sure something unexpected doesn't get
put between the split output of a long buffer.
2007-11-03 07:20:05 +00:00
Wayne Davison
37ce167996 We can't decrement the in_progress value for a hard-linked file until
the generator gets a chance to finish the hard links.
2007-10-18 14:04:42 +00:00
Wayne Davison
71456d301f Write out the inc_recurse flag into a protocol-30 batch file. 2007-10-16 04:08:21 +00:00
Wayne Davison
e5f35681e6 Forward MSG_IO_ERROR to the generator so that it can disable deletions. 2007-10-13 05:23:34 +00:00
Wayne Davison
19531e1f74 Got rid of some unneeded externs. 2007-09-23 02:03:20 +00:00
Wayne Davison
1b42f628f4 Moved inline functions from rsync.h into ifuncs.h. 2007-09-22 16:52:58 +00:00
Wayne Davison
229554084d Added missing "#ifdef ICONV_OPTION" conditionals. 2007-09-18 18:46:03 +00:00
Wayne Davison
ba525f770c - Make use of new iconvbufs() function.
- Convert remote --files-from filenames when -s and --iconv are
  active.
2007-09-18 01:11:45 +00:00
Wayne Davison
da1319128a - Parse hard-link info as soon as we get it in inc_recurse mode.
- Improve the chances of the generator finding a match for a
  hard-link file in inc_recurse mode.
2007-09-15 15:40:57 +00:00
Wayne Davison
f2179fd370 The server should not wait around for an extra end-of-run message. 2007-09-15 15:36:04 +00:00
Wayne Davison
67b8f3dfe7 - Renamed read_line() to be read_line_old().
- Renamed read_filesfrom_line() to read_line() and added args to allow
  the caller to control how it works.
- Added a new function, read_args(), that reads args from a file
  descriptor (using read_line()) and expands any wildcards in them.
  This function has relocated daemon code (from clientserver.c) and
  is also used by the new --protect-args (-s) option.  The new code
  also got rid of an extra strdup() that wasn't needed.
2007-09-09 07:53:12 +00:00
Wayne Davison
35c8fd761f Disabled the debug messages relating to the e_fds vars. 2007-09-03 21:51:59 +00:00
Wayne Davison
29349024c4 Improved the handling of the file-status events received by
the generator.
2007-09-03 21:21:24 +00:00
Wayne Davison
dbe287b701 Needed to use ndx_end in decrement_flist_in_progress(). 2007-07-12 14:04:11 +00:00
Wayne Davison
8e41b68e8f Tweaking the license text a bit more. 2007-07-10 13:55:49 +00:00
Wayne Davison
9decb4d2ef Changed "count" to "used" in struct file_list since there can
be empty items that make the count inaccurate (and the name
somewhat deceiving).
2007-07-07 20:22:05 +00:00
Wayne Davison
4fd842f98d Switching to GPL 3. 2007-07-07 05:33:14 +00:00
Wayne Davison
47cffb77de Handle EINTR in a couple places where we handle the --file-from I/O. 2007-05-26 21:44:19 +00:00
Wayne Davison
1faa1a6da9 Output a -vvv(erbose) message when receiving an incremental file list. 2007-05-23 00:42:32 +00:00
Wayne Davison
332cf6df7c The --iconv option has now made it to the trunk. 2007-04-26 05:53:13 +00:00
Wayne Davison
486f8cd1ab Changed the prerelease-protocol support to use an idiom that will not
slow down the initial version handshake between the two sides.
2007-04-23 19:03:29 +00:00
Wayne Davison
753849fdbc Batch files need to be written with the new subprotocol value
for protocol 30.
2007-04-21 19:32:46 +00:00
Wayne Davison
e4c877cf70 Added a message queue for the receiver->generator messages to handle the case
where the message pipe is being used to forward the file-list data.
2007-04-20 22:39:58 +00:00
Wayne Davison
351e23ad8e - Changed the {read,write}_longint() functions into separate
{read,write}_varlong() and {read,write}_longint() functions:
  the former handles variable-length transmissions, and the
  latter is backward-compatible with older rsync versions.
- Improved the {read,write}_var{int,long}() functions to be
  simpler and to use a different byte order.
- The {read_write}_varlong() functions also allow the caller
  to specify the minimum number of bytes to send.  This allows
  time values to be sent efficiently with a 4-byte minimum,
  while length values continue to be sent with a (more optimal
  for them) 3-byte minimum.
2007-04-20 08:16:53 +00:00
Wayne Davison
f31514adb7 Changed the *_abbbrevint() functions to *_varint(). 2007-04-20 02:17:58 +00:00
Wayne Davison
a0456b9c46 Protocol 30 now uses MD5 checksums instead of MD4. 2007-03-18 06:00:53 +00:00
Wayne Davison
1c3344a105 The ACL support has arrived! This version has a brand new protocol
that makes it incompatible with all prior versions.  A patch will be
provided to allow talking with older (patched) rsync versions.
2007-03-11 00:13:34 +00:00
Wayne Davison
be91bd81b8 Improved the incremental sending of file lists in two ways: (1)
when the sender gets an index of a file to send, we make sure to
send enough future file-list data relative to the new cur_flist
value before we send the data for the file transfer (ensuring that
the generator gets the data in a more timely manner), and (2) the
generator flushes the output socket after each file-list object
has completed its scan so that the sender knows in a more timely
manner that more list data is needed.
2007-02-16 02:35:31 +00:00
Wayne Davison
ba2133d6ad Further modifications to the copyright comment section. 2007-02-04 14:54:58 +00:00
Wayne Davison
121bfb2b4d The ndx arg passed to increment_active_files() is now the unique,
over-the-wire value, making it consistent with the ndx arg that
is passed to decrement_active_files().
2007-02-03 05:13:14 +00:00
Wayne Davison
100018b7cd Mention the year 2007 in the copyright declarations. 2007-01-31 21:46:49 +00:00
Wayne Davison
04c722d5e0 - Renamed done_cnt -> msgdone_cnt.
- Changed increment_active_files() to call check_for_finished_files()
  and to avoid calling both io_flush() and read_msg_fd() in the same
  iteration of a loop (since the former may have called the latter).
2007-01-30 03:57:52 +00:00