[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#20835: rmdir foo/. fails
From: |
Ed Avis |
Subject: |
bug#20835: rmdir foo/. fails |
Date: |
Wed, 17 Jun 2015 11:15:34 +0000 (UTC) |
User-agent: |
Loom/3.14 (http://gmane.org/) |
POSIX documents that EINVAL be returned for rmdir('foo/.') but as far as I
can see from the link you sent it does not document the error status for
rmdir('foo/..') beyond saying that it shall fail. As it happens, it returns
ENOTEMPTY on Linux.
OK, you point out that foo/. might not always be the same thing as foo.
How about this: if foo/. has the same inode number as foo then rmdir proceeds.
If not, it prints an error a bit more helpful than 'Invalid argument'.
--
Ed Avis <address@hidden>