samba-bugs at samba.org
2020-Mar-20 13:29 UTC
[Bug 14323] New: Defaults for --skip-compress are not working, everything is being compressed
https://bugzilla.samba.org/show_bug.cgi?id=14323 Bug ID: 14323 Summary: Defaults for --skip-compress are not working, everything is being compressed Product: rsync Version: 3.1.3 Hardware: All OS: All Status: NEW Severity: normal Priority: P5 Component: core Assignee: wayne at opencoder.net Reporter: simon.matter at invoca.ch QA Contact: rsync-qa at samba.org By default certain file suffixes should not be compressed while rsyncing from remote host. This worked fine for 3.0.6 but doesn't for 3.1.3. In my tests I named an ascii text file as z.gz and rsynced it: [simix at alpha Z]$ rsync-3.0.6/rsync --rsync-path=${PWD}/rsync-3.0.6/rsync -azv alpha:Z/z.gz Z ; rm -vf Z simix at alpha's password: receiving incremental file list z.gz sent 30 bytes received 629254 bytes 83904.53 bytes/sec total size is 628952 speedup is 1.00 removed ?Z? [simix at alpha Z]$ rsync-3.1.3/rsync --rsync-path=${PWD}/rsync-3.1.3/rsync -azv alpha:Z/z.gz Z ; rm -vf Z simix at alpha's password: receiving incremental file list z.gz sent 43 bytes received 63,873 bytes 18,261.71 bytes/sec total size is 628,952 speedup is 9.84 removed ?Z? As you can see the file was compressed on the fly with 3.1.3, which is wrong. I'm wondering if the following change is the culprit here: --- rsync-3.0.6/token.c 2009-01-17 22:41:35.000000000 +0100 +++ rsync-3.1.3/token.c 2018-01-15 04:55:07.000000000 +0100 @@ -45,12 +46,12 @@ static void add_suffix(struct suffix_tre if (ltr == '[') { const char *after = strchr(str, ']'); - /* Just skip bogus character classes. */ - if (!after++) + /* Treat "[foo" and "[]" as having a literal '['. */ + if (after && after++ != str+1) { + while ((ltr = *str++) != ']') + add_suffix(prior, ltr, after); return; - while ((ltr = *str++) != ']') - add_suffix(prior, ltr, after); - return; + } } for (node = *prior; node; prior = &node->sibling, node = node->sibling) { Kind regards, Simon -- You are receiving this mail because: You are the QA Contact for the bug.
samba-bugs at samba.org
2020-Mar-22 09:58 UTC
[Bug 14323] Defaults for --skip-compress are not working, everything is being compressed
https://bugzilla.samba.org/show_bug.cgi?id=14323 --- Comment #1 from Simon Matter <simon.matter at invoca.ch> --- Did some more tests and found the bug was introduced between 3.0.9 and 3.1.0. It seems like handling of default values is not working as expected. -- You are receiving this mail because: You are the QA Contact for the bug.
samba-bugs at samba.org
2020-Apr-08 01:20 UTC
[Bug 14323] Defaults for --skip-compress are not working, everything is being compressed
https://bugzilla.samba.org/show_bug.cgi?id=14323 Wayne Davison <wayne at opencoder.net> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #2 from Wayne Davison <wayne at opencoder.net> --- The code actually grabs the default skip-compress list from the daemon's "dont compress" list, and in recent rsync versions the daemon vars were not initialized in a non-daemon run. I've committed a fix. -- You are receiving this mail because: You are the QA Contact for the bug.