bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: coreutils 'rm /' incompatibility with 2006-06-30 draft POSIX


From: Jim Meyering
Subject: Re: coreutils 'rm /' incompatibility with 2006-06-30 draft POSIX
Date: Sun, 03 Sep 2006 09:51:48 +0200

Paul Eggert <address@hidden> wrote:
> Jim Meyering <address@hidden> writes:
>> You're welcome to make that change.
>
> OK, I installed the following.  This turned into a bigger change than
> I thought it would.  I discovered another problem, which is that the
> POSIX spec says "rm -r ./" should fail (and likewise for ../) but GNU
> rm tries to remove it.  Also, the simplest way to implement the change
> involved an extra 'stat' at the start, which I wanted to avoid, so I
> cached the stat result, and this propagated throughout much of
> remove.c.
>
> I hope the resulting code is clearer and/or more efficient (if not
> please let me know).

It looks fine.
Thanks for doing all that.

It's interesting how often a conceptually simple change
sometimes end up requiring so much engineering.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]