Commit Graph

51 Commits

Author SHA1 Message Date
Wayne Davison
93204ccae2 Made some more char pointers const. 2007-10-28 21:42:41 +00:00
Wayne Davison
969cdffbea Prevent a server from outputting an end-of-run message about its
error-code that cannot be sent successfully.
2007-09-15 15:30:45 +00:00
Wayne Davison
8e41b68e8f Tweaking the license text a bit more. 2007-07-10 13:55:49 +00:00
Wayne Davison
4fd842f98d Switching to GPL 3. 2007-07-07 05:33:14 +00:00
Wayne Davison
377d22ab9f If the server is exiting with an error, delay our exit just a little
in order to give the client side a better chance of reading any error
message we just sent.
2007-05-06 19:44:26 +00:00
Wayne Davison
16edf86595 The improved --xattrs option is landing on the trunk. 2007-04-07 17:22:25 +00:00
Wayne Davison
ba2133d6ad Further modifications to the copyright comment section. 2007-02-04 14:54:58 +00:00
Wayne Davison
e3794138d8 Use the new case_N.h file to make sure that our cleanup_step case
statements never get out of sequence when the code changes.
2006-10-15 15:43:26 +00:00
Wayne Davison
154c345db0 Improved the _exit_cleanup() function to handle potential recursions
back to the function via the calls that it is making.  The new code
treats each recursion back into the function as an opportunity to
take up where we left off (skipping whatever step just failed).
2006-10-14 19:58:52 +00:00
Wayne Davison
2356d73bb4 The cleanup code that handles moving the temp file to the partial
file needed to check that cleanup_fname was not NULL to prevent
any possibility of a recursion starting into that code again.
2006-10-14 02:29:29 +00:00
Wayne Davison
b1b54199ef - When exiting, set the flag "in_exit_cleanup".
- Mark _exit_cleanup() with NORETURN.
- Don't ever return from _exit_cleanup().
2006-10-13 07:38:15 +00:00
Wayne Davison
03dbc0b831 - Improved the setting of cleanup_new_fname and cleanup_fname.
- Don't try to keep a partial file if cleanup_new_fname is not set.
2006-05-18 18:52:40 +00:00
Wayne Davison
1cfcb8af11 Revised the logic for when to call log_exit() to handle the
new --log-file option.
2006-05-09 18:31:00 +00:00
Wayne Davison
e7c67065c0 Updated the FSF's address to an even newer one. 2006-04-25 23:51:12 +00:00
Wayne Davison
0f78b81511 - Updated the address for the FSF in the opening comment.
- Standardized the format of the opening comment, including adding a
  brief description of what's in the file for those that lacked it.
- Added some missing copyright lines.
- Some minor whitespace tweaks (in a few of the files).
2006-04-25 20:23:34 +00:00
Wayne Davison
44e604f416 Simplified the conditional prior to the SIGACTION code. 2006-02-03 18:46:38 +00:00
Wayne Davison
2b28968dfb Call SIGACTION() instead of signal(). 2006-02-02 02:39:25 +00:00
Wayne Davison
ef1f62807e We should be using wait_process(), not waitpid() directly. 2006-02-01 19:25:34 +00:00
Wayne Davison
12fa790ea0 Call finish_transfer() with its newly-added arg. 2006-01-30 07:18:06 +00:00
Wayne Davison
45c49b52a4 Got rid of calls to (the soon to vanish) safe_fname() function. 2006-01-13 21:17:09 +00:00
Wayne Davison
3d7cc5710d If cleanup_set() gets passed a NULL fnametmp or fname, set
cleanup_fname to NULL.
2005-11-10 16:56:32 +00:00
Wayne Davison
054abde25f Handle new IOERR_DEL_LIMIT bit in io_error. 2005-03-05 18:58:38 +00:00
Wayne Davison
4875d6b64d Adding more calls to safe_fname(). 2005-02-07 20:36:43 +00:00
Wayne Davison
58fef0ac38 Changed direct call to fstat() into a call to do_fstat(). 2005-01-28 20:41:36 +00:00
Wayne Davison
d45898df80 Call finish_transfer() with its new arg. 2005-01-10 10:03:06 +00:00
Wayne Davison
09e2bbce8a Call flush_write_file() in _exit_cleanup() if we are keeping a
partially-received file.
2004-10-10 20:31:54 +00:00
Wayne Davison
a7260c4037 Added the new --partial-dir option. 2004-07-29 16:06:38 +00:00
Wayne Davison
b6609cafae - Got rid of cleanup_buf (map-file cleanup is not needed).
- Renamed the cleanup_fd* vars.
2004-07-20 21:35:49 +00:00
Wayne Davison
8186ae6bc0 Tweaked some formatting. 2004-07-02 18:12:24 +00:00
Wayne Davison
6e86c951d7 Call finish_transfer() with its new arg. Also put the externs
at the top and got rid of some trailing whitespace.
2004-05-13 07:08:18 +00:00
Wayne Davison
65fc84b32e Better pid handling. 2004-01-27 08:14:33 +00:00
Wayne Davison
ef732c3b54 Call io_flush() with its new FULL_FLUSH option. 2004-01-15 07:42:12 +00:00
Wayne Davison
6e35c72fdb Return new RERR_VANISHED code, as appropriate. 2003-12-15 08:08:44 +00:00
Wayne Davison
18d6b679af The close_all() function was missing its "void" prototype. 2003-03-21 23:43:50 +00:00
David Dykstra
9f639210ca Prevent the "Connection reset by peer" messages often seen from Cygwin.
Result of a lot of discussion over the last year and a half.  Based on
a patch from Randy O'Meara, cleaned up a bit by Max Bowsher.
2003-01-27 03:35:08 +00:00
David Dykstra
aa2c47d835 Better fix for infinite recursion; don't return from exit_cleanup
unless the nesting is already pretty deep, because there are normal
cases where exit_cleanup is nested shallowly.  Patch from Marc Espie,
posted by Brian Poole.
2003-01-26 03:53:34 +00:00
David Dykstra
b765ec32b9 Prevent infinite recursion in exit_cleanup(). Patch from Sviatoslav Sviridov. 2003-01-16 20:09:31 +00:00
Martin Pool
b0f451eb3b Doc _exit_cleanup. 2002-04-09 05:26:46 +00:00
Martin Pool
e0fde757fd Doc. 2002-04-08 03:38:36 +00:00
Martin Pool
9098bbf3b3 Improved network error handling. (Greg A. Woods) 2002-03-27 01:03:13 +00:00
Andrew Tridgell
19b27a485e improved error handling again. Now we report messages for the remote
shell failing and propogate errors in a better fashion
2001-03-23 01:26:04 +00:00
Andrew Tridgell
ff81e809f4 new error handling system
we now give a non-0 exit code if *any* of the files we have been asked
to transfer fail to transfer
2001-03-22 07:36:51 +00:00
Martin Pool
ef1aa91039 Doc. 2000-11-10 03:17:08 +00:00
Andrew Tridgell
8b35435f7c another hang-at-end fix. It looks like we are more sensiitive to
these with socketpairs. The receiver now sleeps until it gets a signal
to tell it to exit

also fixed test.sh to use the current version remotely
2000-01-30 00:50:19 +00:00
Andrew Tridgell
9bd6597666 set the exit code to RERR_FILEIO is io_error is set when we exit. This
catches most sorts of io errors and ensures we report a error in our
exit status.
1999-04-06 14:52:32 +00:00
Andrew Tridgell
a9766ef147 log filename(line) in exit_cleanup() to make tracking down problems
easier in rsync daemons.
1998-11-15 01:21:42 +00:00
Andrew Tridgell
9b73d1c0e9 put the pid on each line of the log file to facilitate
auto-parsing. Requested by Jarkko Hietaniemi (jhi@iki.fi)
1998-10-29 11:11:38 +00:00
Andrew Tridgell
27d3cdbc94 syslog support in rsync daemon has been broken since I added the "log
file" option. I wonder why noone reported it? Or did everyone just use
"log file" ?
1998-10-28 10:43:31 +00:00
David Dykstra
8638dd48f7 Add "use chroot" and "pid file" rsyncd.conf options. The former allows one
to disable the use of chroot so rsync --daemon can be run as a non-root
user (if a non-privileged --port is used).  The latter allows one to
specify a file in which to write the process id of the daemon, which is
useful when rsync --daemon is not run from inetd.
1998-10-26 21:51:47 +00:00
Andrew Tridgell
c6b81a9865 handle OSes where you can't rename a open file in the cleanup code. 1998-09-09 06:23:27 +00:00