A \ is a shell escape. Every level of shell consumes one level of escape. For every session of a shell every example "\ " becomes " " and every example of "\\" becomes "\".
The raync command line is a mix of local shell commands + commands run via a remote shell via ssh. The simple fact is that if only \ escapes are used, the local shell will utilize those escapes and rsync will never see them. For every level of shell an escape \ does its job. If you want rsync to interpret a space char as other than whitespace then a \ is one way to do so. But one we are talking about the other side of an rsync we are talking about a local command line that consumes a \. Then we are talking about a remote command line that consumes another \. So, within the -e parameter, multiple stacked \ characters are required. Simply put, it is absolutely absurd to \ escape an rsync command line while interpreting the subshell -e parameter and the remote shell parameters the same way. At best you are insisting that ssh do something entirely nonsensical while ensuring that the first s in "ssh" is interpreted as an "s". On 10/28/2016 10:10 PM, Wayne Davison wrote: > > On Fri, Oct 28, 2016 at 5:39 AM, Samuel Williams > <space.ship.travel...@gmail.com <mailto:space.ship.travel...@gmail.com>> > wrote: > > Rsync passed the backslashes through without dealing with them. > > > Yeah, it only does space-splitting and that's all it will ever do. It > still looks to me like there is a bug in the original escaping, since > any command receiving that string is receiving a backslash that is not > supposed to be there. It should only be escaping the string enough to > get it to rsync, not trying to guess what rsync is going to do with it > after it gets it. > > To work around that bug, you could consider using an ssh-calling shell > script instead of manually specifying the ssh command and args to rsync. > > ..wayne.. > > -- ~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._., Kevin Korb Phone: (407) 252-6853 Systems Administrator Internet: FutureQuest, Inc. ke...@futurequest.net (work) Orlando, Florida k...@sanitarium.net (personal) Web page: http://www.sanitarium.net/ PGP public key available on web site. ~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,
signature.asc
Description: OpenPGP digital signature
-- Please use reply-all for most replies to avoid omitting the mailing list. To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html