monotone-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Monotone-devel] nvm.alt_tmpdir


From: Stephen Leake
Subject: Re: [Monotone-devel] nvm.alt_tmpdir
Date: Wed, 18 May 2011 19:27:39 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (windows-nt)

Richard Levitte <address@hidden> writes:

> So, am I getting this right, the issue is actually to move a file from
> one device to another?  

Yes.

> It seems a bit overcomplicated to have a tmpdir option when we could
> simply detect if source and destination are on the same device (the
> structure returned by stat() has the fields st_dev which is to be used
> for this), and select to do something corresponding to 'mv' if it's
> the same, or 'cp' followed by 'rm' if not.

Nathaniel made the same comment.

I also considered just doing copy/remove instead of rename back when I first
proposed this
(http://lists.nongnu.org/archive/html/monotone-devel/2010-12/msg00044.html),
but rejected it as not being in the spirit of monotone.

Now that I see how messy the tmpdir solution actually is, and that the
Win32 code actually does copy/remove on older Win32 versions, I'm happy
to give up on tmpdir and implement copy/remove if fstat shows it's
needed.

So I'll implement that on a new branch.

-- 
-- Stephe



reply via email to

[Prev in Thread] Current Thread [Next in Thread]