Subject: Re: mkdir with trailing / (patch proposed)
To: None <,>
From: der Mouse <mouse@Rodents.Montreal.QC.CA>
List: tech-kern
Date: 05/05/2002 23:39:26
>> [...].  They specify that trailing slashes are to be intrepreted as
>> if there was a trailing '/.'.
> Hmmmm....  Yes.... I see....  [...]
> I really didn't believe it until I read it with my own eyes -- and I
> still can't believe any sane Unix person could stand for it!  Sigh.

I still don't see what the problem is.  That's exactly what I always
thought they already did ("always" = until this discussion); none of
the cases where the differences matter had shown up on my radar.
Basically, my wetware pathname interpretation engine treats a slash as
"prepare for another component, path-so-far must name a directory",
even if the slash is at the end of the string, and I'd assumed namei
behaved similarly.  (This after compressing multiple slashes.)

The only arguments I've seen advanced against this interpretation are

(1) Buh-but that's not what $ANCIENT_UNIX_VERSION did!

(2) There exist applications that assume other semantics.

Of those, (1) is irrelevant, in my opinion; I'd call that a bug in
$ANCIENT_UNIX_VERSION and would greet the change as I would any bugfix.
(2) is more serious, but as the Rationale you quoted points out, an
application cannot count on any existing behaviour to be portable now.

/~\ The ASCII				der Mouse
\ / Ribbon Campaign
 X  Against HTML
/ \ Email!	     7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B