Commit Graph

84 Commits

Author SHA1 Message Date
Wayne Davison
bb1365dd77 Fix see_token zstd case. 2020-07-10 09:47:16 -07:00
Wayne Davison
ab110fc8fb Warning fixes & impossible-failure improvements
- Silence a couple warnings for less-common builds.
- Use a better impossible-failure idiom than assert(0).
2020-07-08 12:26:19 -07:00
Wayne Davison
2bee307592 Get rid of some superfluous lz4 code. 2020-07-04 16:13:00 -07:00
Wayne Davison
85e62c330d Tweak indentation. 2020-07-04 16:10:37 -07:00
Wayne Davison
11eb67eec9 Some memory allocation improvements
- All the memory-allocation macros now auto-check for failure and exit
   with a failure message that incudes the caller's file and lineno
   info.  This includes strdup().

 - Added the `--max-alloc=SIZE` option to be able to override the memory
   allocator's sanity-check limit.  It defaults to 1G (as before).
   Fixes bugzilla bug 12769.
2020-06-25 20:54:21 -07:00
Wayne Davison
73053f26bc Simple change to recv_token(). 2020-06-19 09:55:48 -07:00
Wayne Davison
e63ff70eae Some indentation fixes. 2020-06-13 19:15:02 -07:00
Wayne Davison
7dbbde8c5e Use ZSTD_CLEVEL_DEFAULT define. 2020-06-07 19:30:24 -07:00
Wayne Davison
778f0dff9b Use more switch statements. 2020-06-04 16:17:12 -07:00
Wayne Davison
4c9fdb9f74 Handle --skip-compress right for new compressors
Some compressors can't completely turn off, so minimize the level
when a file is being "skipped".
2020-06-02 18:06:09 -07:00
Wayne Davison
c7f10de442 Switch to using LZ4_compress_default(). 2020-05-28 11:40:52 -07:00
Wayne Davison
c394e86184 Include lz4 compression support.
Based on a patch that was emailed to me without a valid return address.
2020-05-25 13:45:56 -07:00
Wayne Davison
4aaadc2f29 Include zstd compression support.
Based on a patch by Sebastian A. Siewior. Fixes bug #14338.
2020-05-25 13:44:48 -07:00
Wayne Davison
abef92c037 Fix handling of a compressor that has no off_level. 2020-05-25 13:02:56 -07:00
Wayne Davison
d999efe6e5 Make compression-level handling generic. 2020-05-25 11:18:51 -07:00
Wayne Davison
4496e0e8e7 A few more compression tweaks. 2020-05-24 18:43:03 -07:00
Wayne Davison
64d5ea39c0 More compress changes
- Add the zlibx (external-code compatible) compression name.
- Re-enable zlib support with the external library so it can be
  tried as a fallback if zlibx isn't available.
- Add --compress-choice=STR (aka -zz=STR) option.
- Make --cc=STR an alias for --checksum-choice=STR.
- Hook up the new compression negotiation logic.
2020-05-24 17:24:42 -07:00
Wayne Davison
3ba4db7030 Two more spelling fixes and some year updates. 2020-04-16 09:31:02 -07:00
Wayne Davison
d29702134a Spelling fixes from a Fossies run done by Jens. 2020-04-15 17:42:23 -07:00
Wayne Davison
3e2e4b5a33 Tweak the copyright year. 2019-03-16 09:15:49 -07:00
Wayne Davison
473108ae6e Tweak copyright date. 2018-01-14 19:55:07 -08:00
Wayne Davison
453914e35b Update the copyright year. 2015-08-08 12:47:03 -07:00
Wayne Davison
22a3ac0b55 Add new-style compression that skips matching data.
Adding new-style compression that only compresses the literal data that
is sent over the wire and not also matching file data that was not sent.
This new-style compression is compatible with external zlib instances,
and will eventually become the default (once enough time has passed that
all servers support the --new-compress and --old-compress options).

NOTE: if you build rsync with an external zlib (i.e. if you specified
configure --with-included-zlib=no) you will ONLY get support for the
--new-compress option!  A client will treat -z as uncompressed (with a
warning) and a server will exit with an error (unless -zz was used).
2014-04-19 12:18:19 -07:00
Wayne Davison
dfa5b49110 Bump the year to 2014. 2014-01-26 09:29:15 -08:00
Wayne Davison
7e1a9c4d79 Update copyright year. 2013-01-19 11:05:53 -08:00
Wayne Davison
7da17144fd Add compatibility with an unmodified zlib. 2011-11-21 09:22:14 -08:00
Wayne Davison
cbdff74b44 Fix --compress data-duplication bug. 2011-11-21 09:17:17 -08:00
Wayne Davison
3be1d9beb2 Fix compression-ignoring of upper-case suffixes.
Fixes bug 7512.
2010-06-19 09:47:00 -07:00
Wayne Davison
4286ea6036 Don't die if inflate() returns Z_BUF_ERROR in see_deflate_token(). 2009-12-21 10:15:13 -08:00
Wayne Davison
e4c598c830 Make some RERR_* choices better, and another noop_io_until_death() tweak. 2009-11-16 12:35:17 -08:00
Wayne Davison
2f1fb732d4 Improve error handling and get rid of a lingering fprintf(). 2009-09-05 10:25:42 -07:00
Wayne Davison
b3bf9b9df9 Update the copyright year. 2009-01-03 10:57:14 -08:00
Wayne Davison
5dd14f0c33 Split up the ifuncs.h file into 3 .h files. 2008-09-01 19:11:36 -07:00
Wayne Davison
d3d07a5e86 Include 2008 in the copyright years. 2008-03-01 12:01:41 -08:00
Wayne Davison
1b42f628f4 Moved inline functions from rsync.h into ifuncs.h. 2007-09-22 16:52:58 +00:00
Wayne Davison
0d585188f9 Make sure that any "dont compress" patterns that have wildcards in a
suffix match stay in the wildcard-matching list.
2007-07-14 19:36:52 +00:00
Wayne Davison
6e058b4b60 - Added support for the new --skip-compress option.
- Optimized the matching of non-compressing file suffixes.
2007-07-14 19:24:35 +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
ba2133d6ad Further modifications to the copyright comment section. 2007-02-04 14:54:58 +00:00
Wayne Davison
100018b7cd Mention the year 2007 in the copyright declarations. 2007-01-31 21:46:49 +00:00
Wayne Davison
2dc7b8bd0e Got rid of type-casting into isFOO() and toFOO() functions by
using static inline functions that take a signed char pointer.
2006-11-09 02:39:29 +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
ec497df1a0 Optimized set_compression() to remove the per-file strdup(), strlower(),
and free() calls (it now uses iwildmatch()).
2005-12-30 07:19:16 +00:00
Wayne Davison
0fe987e226 Fixed a bug in set_compression() where the default dont-compress
patterns (e.g. *.gz) would not match a pathname containing a slash.
2005-12-30 06:03:40 +00:00
Wayne Davison
e8a8167ad9 Obey new def_compress_level setting. 2005-10-26 16:47:49 +00:00
Wayne Davison
01f439ec6e Fixed a mismatch in the compressed-data handling between how the
sending side and the receiving side handled implicit (unsent) data.
2005-02-14 08:28:00 +00:00
Wayne Davison
acc461c7da Changed various token variables from "int"s to "int32"s. 2005-02-14 08:19:32 +00:00
Wayne Davison
80a25bb880 Backed out changes to send_deflated_token() that surrounded the
call to deflate(..., Z_INSERT_ONLY) -- the underlying bug was
caused by the zlib code not handling Z_INSERT_ONLY in the case
where the server has disabled compression.
2005-01-02 09:08:59 +00:00