Mail Archives: djgpp-workers/2001/04/29/02:31:21
On Sat, 21 Apr 2001, Richard Dawe wrote:
> I'd like to announce beta 2 of the port of Fileutils 4.0 to DJGPP.
> Fileutils is a collection of programs like cp, mv, rm, ls for basic file
> manipulation. The beta is available here:
>
> http://www.phekda.freeserve.co.uk/richdawe/djgpp/fileutils/
I think I found a bug in this port. Put a floppy into drive A: and
then try this:
C:\> mkdir a:\foo
C:\> cd a:\
C:\> rm -rf a:/foo
c:/djgpp/bin/ls: a:/foo: Resource busy (EBUSY)
On plain DOS, this fails with EBUSY, even though the `cd' command
above makes sure a:\foo is _not_ the current working directory on A:,
and the directory is not removed. On Windows, `rm' succeeds to remove
the directory (evidently because Windows doesn't have problems with
removing CWD), but then you have this problem:
C:\> ls a:
c:/djgpp/bin/ls: a:: No such file or directory (ENOENT)
To me, this sounds like `rm' chdir's to the directory it wants to
empty, which then gets it in trouble when it wants to remove the
directory itself.
I didn't look into the sources to try to find out why does this
happen. Let me know how can I help you debug this.
- Raw text -