another unix joke

Keith Bostic bostic at ucbvax.BERKELEY.EDU
Thu Sep 15 08:20:08 AEST 1988


In article <8488 at smoke.ARPA>, gwyn at smoke.ARPA (Doug Gwyn ) writes:
> More UNIX jokes, from 4.3BSD:
> 
> $ mkdir foo/
> mkdir: foo/: No such file or directory
> $ mkdir foo
> $ rmdir foo/
> rmdir: foo/: Is a directory

Though I'm not sure what you're trying say, the behavior you're
objecting to is correct.  As the NULL pathname is, by convention,
the equivalent of ".", "foo/" is the same as "foo/.". Creating
or removing "foo/." is illegal.  While it is arguable that the
returned error should be different, or perhaps explicitly documented,
4BSD is doing the right thing.  As POSIX 1003.1 does not support
the equivalence of the NULL path and ".", the problem will die a
natural death.

Keith Bostic



More information about the Comp.unix.questions mailing list