bug-coreutils
[Top][All Lists]
Advanced

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

Re: design question, why not always use 'cp --remove-destination'?


From: Krasimir Angelov
Subject: Re: design question, why not always use 'cp --remove-destination'?
Date: Tue, 22 Aug 2006 18:16:39 +0300

On 8/22/06, Frederik Eaton <address@hidden> wrote:
Perhaps the "Text file busy" error is Unix-specific, but I can imagine
cases where somebody (other than the OS) might open a file with a
well-known name and read from various parts of it, and expect it not
to change underneath them...

Then he/she may expect that the file will not be suddenly unlinked
while he/she is still reading. The documentation for System.IO says
that the implementation should provide single writer - multiple
readers locking. When that is the case then copyFile should fail if
the target fail is open for reading or writing from someone including
the OS. The Unix implementation provides only local locking but the
Windows implementation provides system wide locking.

Cheers,
  Krasimir




reply via email to

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