GNU bug report logs -
#24714
delete-directory race condition
Previous Next
Reported by: Glenn Morris <rgm <at> gnu.org>
Date: Mon, 17 Oct 2016 02:21:01 UTC
Severity: normal
Found in version 25.1
Fixed in version 26.1
Done: Glenn Morris <rgm <at> gnu.org>
Bug is archived. No further changes may be made.
Full log
Message #21 received at 24714 <at> debbugs.gnu.org (full text, mbox):
Andreas Schwab wrote:
> That is ok. The operation cannot successfully be completed in this case.
>
>> Frankly I don't see how Emacs's delete-directory can work reliably as
>> currently implemented.
>
> A property it shares with any other operation recursing on directories,
> in Emacs or elsewhere.
That's interesting. I'd assumed there was a "Right Way" to do it, and
that it would be whatever coreutil's rm did. If not then we are back to:
> delete-directory should simply catch ENOENT errors and ignore them
> when it deletes files and subdirectories under the "recursive" option.
> Other errors should signal an error as they do now.
This doesn't seem possible without changes at the C level.
Should there be a standard Lisp error for ENOENT?
Currently report_file_errno only does EEXIST -> file_already_exists.
Or should delete-file get a FORCE argument akin to "rm -f"?
This bug report was last modified 8 years and 263 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.