This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: Deletion race in NtSetFileInformation ? (Directory not empty error in rm -r -f)
Corinna Vinschen wrote:
> ...or having a cwd below the directory. Trying to remove a directory
> which is the CWD of some process is the most common reason that the
> directory is blocked, because the Win32 CWD is opened without the
> FILE_SHARE_DELETE flag. Especially something like `rm -rf ../foo'
> is suspicious, if foo is the CWD of the current shell.
Hmm ... the other thing that I just remembered is that I first noticed
this problem on 1.7.5-1 on Win7, and the thing that made me suspicious
was that replacing the offending command with:
strace rm -f -r ...
made the command suddenly work! But ...
sleep 1 ; rm -f -r ...
failed in the same way :-(
I haven't tried reproducing this particular behaviour on 1.7.7 (yet).
Earl
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple