Re: Bug in mkdir: Misleading Error Message

2004-09-07 Thread Dmytro Taranovsky
Paul Eggert wrote: > Unfortunately nicening up the messages wouldn't be that easy, as the > most natural implementation of mkdir is to use the mkdir system call > and to use perror when it fails. As far as I know, mkdir prints "No such file or directory" only when the parent directory does not exi

Re: Bug in mkdir: Misleading Error Message

2004-09-07 Thread Paul Eggert
Dmytro Taranovsky <[EMAIL PROTECTED]> writes: > As far as I know, mkdir prints "No such file or directory" only when the > parent directory does not exist Only if by "not exist" you mean "mkdir() fails with errno==ENOENT", which is a bit circular. For example: $ rm -f x y $ ln -s x y $

Re: Bug in mkdir: Misleading Error Message

2004-09-06 Thread Paul Eggert
Dmytro Taranovsky <[EMAIL PROTECTED]> writes: > mkdir: cannot create directory `new/new': No such file or directory Here's another good one: $ mkdir /bin/sh/foo mkdir: cannot create directory `/bin/sh/foo': Not a directory > mkdir should print a more accurate error message, Well, the exist

Bug in mkdir: Misleading Error Message

2004-09-06 Thread Dmytro Taranovsky
Description: Suppose that the current directory has no file or directory named new and you invoke mkdir new/new The output is the error message mkdir: cannot create directory `new/new': No such file or directory This appears to claim that 'new/new' cannot be created because it does not exist. How