The Samba-Bugzilla – Bug 5199
Exclusion of source arg ancestor short-circuits recursion
Last modified: 2008-01-23 23:33:23 UTC
I originally reported this bug here:
In incremental recursion mode, the exclusion of an ancestor dir of a source argument incorrectly short-circuits the traversal of the source argument, even with --no-implied-dirs. I expect rsync to omit the ancestor dir from the file-list (moot with --no-implied-dirs) but traverse the source argument regardless, as rsync 2.6.9 does.
$ mkdir src src/D
$ rsync -ni -rR --exclude='/src' src/D/ dest/
$ rsync -ni -rR --no-implied-dirs --exclude='/src' src/D/ dest/
(Still no output)
$ rsync-2.6.9 -ni -rR --exclude='/src' src/D/ dest/
The latest dev version now has this fixed. We no longer allows the filtering of any implied directories except via --no-implied-dirs. This fixes the weirdness in earlier versions where an exclude would elide the sending of the directory's information without stopping the sending of its contents.
IMHO, the old behavior of excluding just the implied dir from the file-list was useful, not weird...but anyway the important problem is fixed.