Commit Graph

  • 61542c41de Decided that we don't need to limit the block size after all now that the map_file() code handles large block sizes better. Wayne Davison 2004-08-03 15:41:16 +00:00
  • bd1a581bee Use MAX_MAP_SIZE in the args to map_file(). Wayne Davison 2004-08-03 15:37:54 +00:00
  • 6e8a1782ab - Changed the calling syntax for map_file() so that it takes both a (possibly approximate) window size and an optional block size (which is used to round-up the window size if it is non-zero). - Don't set window_start behind the supplied offset in map_ptr(). Wayne Davison 2004-08-03 08:05:29 +00:00
  • 96d910c770 Call map_file() with its new args, including a suggested window size. Wayne Davison 2004-08-03 08:05:27 +00:00
  • 7560c17adc We call map_ptr() with a data range than includes any unmatched data (which we might need to reference again) in addition to the current rolling-checksum block (this prevents the unmatched data from being lost when we slide the buffer and read more data). Wayne Davison 2004-08-03 08:05:23 +00:00
  • 9cd339eb39 - Changed the description for --block-size in the --help text. - Use the new MAX_BLOCK_SIZE to limit the block_size value. Wayne Davison 2004-08-03 08:05:20 +00:00
  • f310029387 - Added define for MAX_BLOCK_SIZE. - Increased the MAX_MAP_SIZE. Wayne Davison 2004-08-03 08:05:17 +00:00
  • 3ed8eb3f9c Updated the description of the --block-size option. Wayne Davison 2004-08-03 07:58:48 +00:00
  • 007351494d Mention the open64()/mkstemp64() configure change. Wayne Davison 2004-08-02 22:06:17 +00:00
  • 6dcb93208d Don't use mkstemp() if the OS has open64() but not mkstemp64(). Wayne Davison 2004-08-02 21:56:07 +00:00
  • 84e1a698bf Test for functions open64() and mkstemp64(). Wayne Davison 2004-08-02 21:54:49 +00:00
  • 0d7638eafd Got rid of trailing whitespace. Wayne Davison 2004-08-02 16:49:20 +00:00
  • 86e2f445f7 Mention the "refuse options" change. Wayne Davison 2004-08-02 07:41:04 +00:00
  • 093e816c37 Allow better wildcard matching against the short-option letters in the "refuse options" handling. Wayne Davison 2004-08-02 07:40:34 +00:00
  • 1cb0a3edc6 Document the improved "refuse options" syntax. Wayne Davison 2004-08-02 05:01:36 +00:00
  • 06a5054273 - Extended the "refuse options" daemon setting to allow wildcards and to allow single-letter option names. - No need to send the various --delete* options or the --force option from the receiver to the sender. Wayne Davison 2004-08-02 05:00:30 +00:00
  • acd0299243 Got rid of unused externs. Wayne Davison 2004-08-02 04:50:33 +00:00
  • dca68b0aad - Changed "read so far" to "received so far". - Output the who_am_i() information in the socket read/write errors to make it a little clearer who is complaining about what (for those familiar with rsync, at least -- e.g. it will help when users report errors). Wayne Davison 2004-08-02 02:43:54 +00:00
  • c3ea09906d - Changed all the errors in parse_arguments() to use the err_buf so that a client talking to a daemon server actually gets the error. - If a daemon has a list of exclusions, apply that list to various options to ensure that an excluded file can't be affected. - Fixed an arg-checking problem when --files-from got passed to a daemon. Wayne Davison 2004-07-31 20:09:54 +00:00
  • bf4679e8a0 If we need to return an error during the startup phase and the other side is expecting us to send them a files-from list, send the list terminator before sending the error. Wayne Davison 2004-07-31 19:55:42 +00:00
  • c4054610c8 Don't allow a --partial-dir setting to overwrite a server-excluded file (affects a daemon receiver only). Wayne Davison 2004-07-31 18:13:20 +00:00
  • f6c0d3d70b - Document the change to --copy-links. - Improved the "OUTPUT CHANGES" section. Wayne Davison 2004-07-31 16:20:28 +00:00
  • ef855d198e Document the old side-effect to --copy-links and that it no longer happens in a modern rsync w/o --keep-dirlinks. Wayne Davison 2004-07-31 16:19:14 +00:00
  • 81b07870c8 One call to link_stat() (in set_perms()) needed to honor the setting of keep_dirlinks if the current item is a directory. Wayne Davison 2004-07-31 16:15:41 +00:00
  • bb6721dce6 Reset copy_links in the receiver. Wayne Davison 2004-07-31 16:14:27 +00:00
  • 446a2987cd Prominently mention the changes to the text that gets output. Wayne Davison 2004-07-31 03:33:05 +00:00
  • 4de2a17409 Changed "wrote"/"written" to "sent" and "read" to "received" in the text that is output. Wayne Davison 2004-07-31 03:32:42 +00:00
  • 99d24f77ed - Mention the "list = no" change in error handling. - Improved a few of the NEWS items. Wayne Davison 2004-07-30 22:46:07 +00:00
  • c0422cea9f If someone is denied access to a "list = no" module, lie and tell them that the module is "Unknown" (so the user can't probe to find unlisted modules). Wayne Davison 2004-07-30 20:07:52 +00:00
  • 8b6ad0193d Don't ignore case in lp_number() because the rest of the daemon code can't handle the case where the module name doesn't exactly match the string the user provided. Wayne Davison 2004-07-30 20:05:37 +00:00
  • 33eff8bfd6 If we reject a name due to a server-exclude, someone is trying to hack rsync (because the generator would not have included this file). Respond with an exit. Wayne Davison 2004-07-30 07:02:37 +00:00
  • 65af3dab03 Document the latest changes. Wayne Davison 2004-07-29 18:08:16 +00:00
  • 065a605270 Got rid of bogus compare_dest scan in skip_file() -- it must checksum the same file that we used for the stat() (in the parent routine). Wayne Davison 2004-07-29 16:45:48 +00:00
  • a7260c4037 Added the new --partial-dir option. Wayne Davison 2004-07-29 16:06:38 +00:00
  • 44cad59f2b Document the new --partial-dir option. Wayne Davison 2004-07-29 16:06:34 +00:00
  • c52461f911 Check the error return of flush_write_file(). Wayne Davison 2004-07-29 07:37:27 +00:00
  • 7f459268d9 Added close_multiplexing_in() and renamed io_multiplexing_close() to close_multiplexing_out(). Wayne Davison 2004-07-29 07:24:45 +00:00
  • 9eeb3b9c88 Call the new close_multiplexing_in() function in the generator. Wayne Davison 2004-07-29 07:24:00 +00:00
  • d1b31da71e If we fail writing to the socket and we're receiving error messages from the other side via a multiplexed input, read the socket to see if we get some errors that would explain why they went away. Wayne Davison 2004-07-29 07:09:46 +00:00
  • 89e540e638 One more inplace code tweak. Wayne Davison 2004-07-29 06:59:30 +00:00
  • fab65a5bc2 Some minor fixes and improvements for the inplace code. Wayne Davison 2004-07-29 06:40:26 +00:00
  • e7d13fe532 - Explicitly save the stat()'s errno so that we can be sure we're testing the right thing lower down (and so that future code doesn't always have to remember to save it off and restore it). - Improved a chunk of link_dest code. - Handle the removal of a non-regular file without so much duplicated code. Wayne Davison 2004-07-28 10:04:06 +00:00
  • ecc81fce17 Use the new safe_fname() function. Wayne Davison 2004-07-26 16:36:59 +00:00
  • b4afd23c30 Allow safe_fname() to tweak up to two name at a time. Wayne Davison 2004-07-26 16:34:36 +00:00
  • af1a3f9b6e Use safe_fname() in full_fname(). Wayne Davison 2004-07-26 15:59:51 +00:00
  • 820b6c9aa0 Added safe_fname() that converts any newlines in a name into '?'s. Wayne Davison 2004-07-26 15:52:25 +00:00
  • 3cb22c204c Made a comment better. Wayne Davison 2004-07-26 05:38:02 +00:00
  • 7432ccf4ed Some batch-mode changes. Wayne Davison 2004-07-24 16:51:58 +00:00
  • 6a48e792c1 Made the new option-twiddling message only output when verbose. Wayne Davison 2004-07-24 16:51:16 +00:00
  • 9459290ae7 Call read_stream_flags() as soon as we open the batch file for reading. Wayne Davison 2004-07-24 16:40:41 +00:00
  • 741d654495 Call write_stream_flags() from start_write_batch(). Wayne Davison 2004-07-24 16:39:53 +00:00
  • d3e182af09 Added write_stream_flags() to write the state of certain flags into the batchfile and read_stream_flags() to read and twiddle the same flags. This ensures that the batchfile reading doesn't get confused about what data to expect from the socket. Wayne Davison 2004-07-24 16:38:49 +00:00
  • d9b4d267c7 Tweaked a compound line. Wayne Davison 2004-07-23 16:59:38 +00:00
  • 58c5c24555 Added a comment. Wayne Davison 2004-07-23 16:59:22 +00:00
  • 341c9a137f Some basic batch-mode tests. Wayne Davison 2004-07-23 02:13:34 +00:00
  • 871446fc98 Chris added a missing "not" to a comment. Wayne Davison 2004-07-23 01:40:22 +00:00
  • 0abda1b176 Fixed the opening comments. Wayne Davison 2004-07-23 01:39:19 +00:00
  • 394bcdb5e3 If we sucessfully renamed a file that has multiple links to it, unlink() it to ensure that rename() didn't lie to us (which it does if you try to rename() a file over another link to the same file). Wayne Davison 2004-07-22 22:52:39 +00:00
  • 28deecca55 Changed NO_INT64 to INT64_IS_OFF_T because off_t might actually be 64 bits. The code now only complains if int64 is really too short. Wayne Davison 2004-07-22 19:28:45 +00:00
  • 4db88e5b8f Some --help text fixes. Wayne Davison 2004-07-22 15:43:28 +00:00
  • 75b243a51d Some more --inplace improvements. Wayne Davison 2004-07-22 15:41:09 +00:00
  • 9bccfc429c Should always call finish_transfer() for inplace handling, just like for keep_partial handling. Wayne Davison 2004-07-22 15:31:06 +00:00
  • 077e59b769 The inplace handling in finish_transfer() now passes PERMS_SKIP_MTIME to set_perms() if ok_to_set_time wasn't specified. Wayne Davison 2004-07-22 15:30:04 +00:00
  • 007e3c0e9a Need to output the "failed verification" error before sending the MSG_REDO so that the output comes out in the right order. Wayne Davison 2004-07-22 08:16:35 +00:00
  • e2bc412669 Added a warning message when a file fails to verify, letting the user know if we retained it or discarded it. Especially useful for batch- reading mode where the old code could look like it did the update when it really silently failed. Wayne Davison 2004-07-22 04:15:18 +00:00
  • e344209582 Added even more double-quoting. Wayne Davison 2004-07-22 03:23:04 +00:00
  • e76ca1458c No need to check both delete_after and delete_mode since the former implies the latter. Wayne Davison 2004-07-22 02:52:57 +00:00
  • 16cc9ca2c9 In read_batch mode, we read ints from the new batch_gen_fd pipe and only process the updates from the batch file when the generator has indicated that it is ready (which ensures that all the necessary dirs have been created). Wayne Davison 2004-07-21 23:59:37 +00:00
  • 8c90957ff5 Got rid of read_batch special case. Wayne Davison 2004-07-21 23:59:33 +00:00
  • c0d8e84c9d Setup for read_batch mode a little differently: - Avoid calling local_child(). - Create a pipe that lets the generator send us index values. - Set batch_gen_fd for the receiver to read the pipe. Wayne Davison 2004-07-21 23:59:31 +00:00
  • b0ad542928 Added batch_gen_fd. Wayne Davison 2004-07-21 23:59:28 +00:00
  • 727b35f665 In read_batch mode, we now let the code write out the index value to the f_out pipe before we return from recv_generator(). This gives the receiver something to sync with so that it doesn't rush ahead of us (which could be bad if we didn't have a chance to create the destination dirs yet). Wayne Davison 2004-07-21 23:59:25 +00:00
  • aa4343211f Don't write out the protocol_version number in read_batch mode. Wayne Davison 2004-07-21 23:59:22 +00:00
  • 3611989355 Complain if the user combines --read-batch with --files-from. Wayne Davison 2004-07-21 22:50:11 +00:00
  • 3381b77d71 Improved the test a little. Wayne Davison 2004-07-21 21:06:13 +00:00
  • dce70db374 Adding a test for the --compare-dest option. Wayne Davison 2004-07-21 20:58:32 +00:00
  • 2adbcdc7ea A couple am_sender checks (one negated) were not needed. Wayne Davison 2004-07-21 20:17:02 +00:00
  • 7e5fa372cf Call map_file() with the new block_size arg (had to delay the call to map_file() until the block size was known). Wayne Davison 2004-07-20 21:35:58 +00:00
  • 6e45e1dd86 - Call map_file() with the new block_size arg (had to delay the call to map_file() until the block size was known). - Got rid of the setting of max_map_size. Wayne Davison 2004-07-20 21:35:55 +00:00
  • 7f290d5c82 - Added a new block_size arg to map_file(). Use it to set the new def_window_size member variable. - Got rid of max_map_size global (we use def_window_size now). Wayne Davison 2004-07-20 21:35:52 +00:00
  • b6609cafae - Got rid of cleanup_buf (map-file cleanup is not needed). - Renamed the cleanup_fd* vars. Wayne Davison 2004-07-20 21:35:49 +00:00
  • efa95a1842 Call map_file() with its new block_size arg. Wayne Davison 2004-07-20 21:35:46 +00:00
  • 51bd4f0f3a Tweaked an error message. Wayne Davison 2004-07-20 21:10:20 +00:00
  • 562b61695e Added a def_window_size variable to struct map_struct. Wayne Davison 2004-07-20 21:08:33 +00:00
  • 98f51bfb56 - More batch-file improvements. - A few spelling fixes. Wayne Davison 2004-07-20 18:12:50 +00:00
  • 73f0ce69e7 We now append the exclude list as a "here" document to the end of the BATCH.sh file. Wayne Davison 2004-07-20 17:07:55 +00:00
  • cf338ab1be Made write_sbuf() non-static. Wayne Davison 2004-07-20 16:57:18 +00:00
  • 66a9dc9639 Changed write_batch_argvs_file() to new write_batch_shell_file() call (with extra arg). Wayne Davison 2004-07-19 17:11:41 +00:00
  • 8ed9d849dc Added new function discard_receive_data(). Wayne Davison 2004-07-19 17:05:01 +00:00
  • 5ebab6c10c - Don't allow some crafty user to try to force us to update a server-excluded file. - If get_tmpname() fails we need to discard the update using receive_data(). Wayne Davison 2004-07-19 16:37:30 +00:00
  • e7a69008e6 Do a better job of writing out the BATCH.sh file (i.e. quote special characters and spaces in args, omit all the source args, omit the include/exclude args if we can). Wayne Davison 2004-07-19 08:27:17 +00:00
  • 73e015683c Changed batch.rsync_argvs to batch.sh. Wayne Davison 2004-07-19 03:59:35 +00:00
  • b462781fd0 Fixed the argv munging to work properly regardless of whether the user specified a trailing '=VALUE' or put the value in a separate arg. Wayne Davison 2004-07-19 00:53:49 +00:00
  • 93095cbe99 A very minor optimization was made to read_sbuf(), read_byte(), write_sbuf(), and write_byte(). Wayne Davison 2004-07-17 21:17:34 +00:00
  • 399371e7b5 - Improved the warning about --inplace. - Fixed the sentence describing how to read standard input with --read-batch. Wayne Davison 2004-07-17 16:44:16 +00:00
  • d7142e2328 Moved the read_batch abort check below the code that handles the symlinks and devices. Wayne Davison 2004-07-17 16:29:10 +00:00
  • 1f75bb1066 Revamped some of the io variables and calls to make the various I/O functions seemlessly work on fds that aren't for the main socket. This involved changing some fd-variable names (to make them clearer), adding io_set_sock_fds(), and making input buffering have a better enabled flag (via an allocated buffer, just like the output buffering). I also got rid of the fd arg to some functions where the fd arg could only specify the input or output fd for the socket (which we already know). Wayne Davison 2004-07-17 15:20:00 +00:00
  • 088adfacc1 Got rid of the arg to io_start_multiplex_out(). Wayne Davison 2004-07-17 15:19:57 +00:00
  • da3478b2a7 - Got rid of the arg to the io_start_multiplex_{in,out}() calls. - Call io_set_sock_fds(). Wayne Davison 2004-07-17 15:19:54 +00:00
  • 5126ed1ef0 Changed a MIN() to a MAX() when setting max_map_size. Wayne Davison 2004-07-17 10:59:14 +00:00