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

Re: svn commit: r1004286 - in /subversion/trunk: ./ subversion/libsvn_subr/io.c

From: Daniel Shahaf <d.s_at_daniel.shahaf.name>
Date: Tue, 11 Jan 2011 20:21:57 +0200

Daniel Shahaf wrote on Tue, Jan 11, 2011 at 18:34:57 +0200:
> Ramkumar Ramachandra wrote on Tue, Jan 11, 2011 at 21:33:33 +0530:
> > - /* Get the perms for a newly created file to find out what bits
> > - should be set.
> > -
> > - Normally del_on_close can be problematic because APR might
> > - delete the file if we spawned any child processes. In this
> > - case, the lifetime of this file handle is about 3 lines of
> > - code, so we can safely use del_on_close here.
> > -
> > - Not so fast! If some other thread forks off a child, then the
> > - APR cleanups run, and the file will disappear. So use
> > - del_on_pool_cleanup instead.
> > -
> > - Using svn_io_open_uniquely_named() here because other tempfile
> > - creation functions tweak the permission bits of files they create.
> > - */
> > - SVN_ERR(svn_io_open_uniquely_named(&fd, NULL, NULL, "svn-tempfile", ".tmp",
> > - svn_io_file_del_on_pool_cleanup,
> > - scratch_pool, scratch_pool));

Why did you remove the comment? (I think it should be retained.)
Received on 2011-01-11 19:25:48 CET

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