[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: `svn co` creates files with wrong permissions

From: Stefan Sperling <stsp_at_elego.de>
Date: Sun, 1 Nov 2009 22:51:22 +0100

On Sun, Nov 01, 2009 at 07:53:00PM +0100, Daniel Näslund wrote:
> > We may want to look for more places where temporary files end up being
> > installed in the working copy and make sure to always set permissions
> > properly. Anyone up for a bite-sized task like this? Scanning the code
> > or use of temporary files should give anticipating developers lots of
> > opportunity to learn.
>
> I took the bait! Started grepping and thought that I might just as well
> keep what I've found here as on my hard drive.

Thanks!

> I found that the mkstemp system call is passed up this way:
>
> [[[
> svn_subst_copy_and_translate3()
> svn_io_write_unique(), svn_stream_open_unique()
> svn_io_open_unique_file3()
> svn_io_file_mktemp()
> apr_file_mktemp()
> mkstemp()
> ]]]
>

That's a nice list.

I have a patch in progress now which will solve this problem within
svn_io_open_unique_file3(), to repair the breakage caused. We can still
fix all the callers copying/renaming tempfiles into WORKING, however,
and then svn_io_open_unique_file3() won't have to bother with permissions.

Stefan

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=2413517
Received on 2009-11-01 22:52:00 CET

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.