patch against manpage
jw schultz
jw at pegasys.ws
Thu Mar 13 01:31:29 EST 2003
On Wed, Mar 12, 2003 at 02:55:55PM +0100, Paul Slootman wrote:
> On Wed 12 Mar 2003, jw schultz wrote:
> > On Wed, Mar 12, 2003 at 01:27:32PM +0100, Paul Slootman wrote:
> > > This is a patch against the manpage to clarify what the --perm option
> > > does and does not do.
> >
> > If we are going to embellish this description it would be
> > good to make it clear that the behavior of rsync in this
> > regard is the same as that of cp.
> >
> > Most of those complaining about this behavior fail to
> > understand it is consistent with cp, scp, rcp et al.
>
> Not quite true, I'm afraid...
>
> $ ls -l /tmp/ps*
> -rw-rw-r-- 1 paul paul 1266 Mar 12 14:49 /tmp/ps1
> $ cp /tmp/ps1 /tmp/ps2
> $ ls -l /tmp/ps*
> -rw-rw-r-- 1 paul paul 1266 Mar 12 14:49 /tmp/ps1
> -rw-r--r-- 1 paul paul 1266 Mar 12 14:51 /tmp/ps2
>
> Note how the permissions are different! That's because cp pays attention
> to the umask. Only with the -p option does cp preserve the permissions,
> even if the destination doesn't exist.
And rsync does exactly the same. New file permissions won't
be looser than umask but they may be tighter.
This is done at the end of receive_file_entry()
--
________________________________________________________________
J.W. Schultz Pegasystems Technologies
email address: jw at pegasys.ws
Remember Cernan and Schmitt
More information about the rsync
mailing list