[RFC] per-branch umask
Jan Hudec
bulb at ucw.cz
Thu Dec 15 20:32:43 GMT 2005
On Thu, Dec 15, 2005 at 12:46:07 -0600, John Arbash Meinel wrote:
> Matthieu Moy wrote:
> > Jan Hudec <bulb at ucw.cz> writes:
> >
> >
> >>Ok or not, sftp does not support setting umask, so it's the only way
> >>(short of requiring users to create wrapers for the sftp server).
> >
> >
> > If the performance loss is visible, then there should be a way to
> > disable the chmod.
> >
>
> Actually, I found a better way. The CMD_OPEN call for sftp lets you
> specify a file mode at creation time.
> Since sftp.put() always uses _sftp_open_exclusive() and puts the file
> into a temporary file, we probably don't have to chmod the file again.
So does open -- but masks it with umask. Isn't sftp the same case?
> Which means that the only real overhead is an extra stat() call when you
> open the branch, to determine the permissions of the branch. And a
> couple extra bytes which pass the mode bits.
>
> John
> =:->
>
--
Jan 'Bulb' Hudec <bulb at ucw.cz>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20051215/09df4087/attachment.pgp
More information about the bazaar
mailing list