Subject: Re: Linux emulation and mkdir with trailing /
To: None <tech-kern@netbsd.org>
From: Alan Barrett <apb@cequrux.com>
List: tech-kern
Date: 09/25/2000 12:54:45
On Sun, 24 Sep 2000, Christos Zoulas wrote:
> Having said that, it would be nice if:
> - the emulations DTRT
> - if posix really says that the trailing slashes are ignored:
> - provide posix_ functions [but that is a pain because
> there are too many of them, and it adds a lot of crud].
> - provide a sysctl to turn this on [this is *really*
I don't know what the standards say, or what traditional behaviour was.
But if I ever type a name with a trailing slash, then I intend that name
to be interpreted as a directory, and I expect to get an error if it
is a (non-directory) file. For example, if foo exists as a file and I
say "mv foo bar/", then I want to get an error if bar does not already
exist as a directory; I certainly don't want to end up with bar as a
file. Similarly, if I type "install myprogram /usr/local/bin/" but
/usr/local/bin does not exist, then I want an error message, I don't
want to end up with /usr/local/bin as an executable program.
--apb (Alan Barrett)