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

Re: svn commit: r1682265 - /subversion/trunk/subversion/libsvn_fs_fs/util.c

From: Philip Martin <philip.martin_at_wandisco.com>
Date: Thu, 28 May 2015 18:11:48 +0100

Ivan Zhakov <ivan_at_visualsvn.com> writes:

> 1. Make svn_io_file_name() consistently return error for cross volume
> renames by fixing APR or using platform specific code.
> 2. For all platforms handle APR_STATUS_IS_EXDEV() like this: copy file
> to temporary file in the same folder as destination and then rename
> it.
>
> I'm ready to implement it if nobody object.

We do most (all?) of that. svn_io_file_rename() calls apr_file_rename()
and on Unix that calls rename() which can fail with EXDEV. When that
happens svn_io_file_rename() fails.

svn_io_file_move() catches EXDEV and copies the file to a temporary in
the destination directory and then calls apr_file_rename().

-- 
Philip Martin | Subversion Committer
WANdisco // *Non-Stop Data*
Received on 2015-05-28 19:12:07 CEST

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.