lkml.org 
[lkml]   [1999]   [Feb]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: rmdir of one's pwd (was Re: rmdir of a busy directory)
    From: Ralf Corsepius <corsepiu@faw.uni-ulm.de>

Linus Torvalds wrote:

> Show me POSIX or other standards that say that you can't do it, and I
> guess I have to work around a standards problem, but right now I say that
> if programs ask for 'rmdir(".")', then they had better get it. I don't
> think the OS should second-guess anybody.
I don't know about a formal standard, either.

Nevertheless, in my initial post, I wasn't talking about rmdir (2), I was
talking about rmdir(1)'s behaviour on linux-2.[12].x breaking gcc/fixincludes
for building cross-compilers.

A formal standard for rmdir(1) can be found in POSIX.2
(I have the 1993-12-22 edition here).
It says:

"The rmdir utility shall remove the directory entry specified by each operand,
which shall refer to an empty directory."

No exception is made for ".".
Thus, gcc/fixincludes needs fixing.

Andries

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:50    [from the cache]
©2003-2011 Jasper Spaans