[Top][All Lists]

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

Re: BUG in "cvs co -r" (CVS 1.11.0)?

From: Alexei Lioubimov
Subject: Re: BUG in "cvs co -r" (CVS 1.11.0)?
Date: Fri, 4 Jan 2002 21:57:02 +0300

I'm sending this bug (opendir()) to address@hidden mailing list.

Alexei Lioubimov

----- Original Message -----
From: "Larry Jones" <address@hidden>
To: <address@hidden>
Cc: <address@hidden>
Sent: Thursday, January 03, 2002 10:59 PM
Subject: Re: BUG in "cvs co -r" (CVS 1.11.0)?

> Greg A. Woods writes:
> >
> > So, therefore the first and most important question to ask Alexei is
> > whether or not there was some other filesystem object called "Attic"
> > before the manual mkdir of the new empty Attic directory.  Only if not
> > then could there may be a bug in the OS.
> He strongly implied there was not -- particularly since he was able to
> create the Attic directory by hand, which he would not have been able to
> do if there were some other object with that name.
> > existence_error() is defined with this rather ugly but no doubt more
> > portable mess:
> [...]
> > (why can't POSIX-compatible systems stick to the basics in basic
> > situations like this?!?!?!??!  having to go to such lengths for the sake
> > of POSIX portability is stupid)
> I think the mess is due to systems that try to be Unix-like without
> actually conforming to POSIX.  As far as I can see, ENOTEXIST, EOS2ERR,
> and EVMSERR (which are the cause of the mess) are definitely not part of
> POSIX.  (I can guess where EOS2ERR and EVMSERR came from, does anyone
> know where ENOTEXIST came from?)
> > On most systems opendir() calls open(2), which says:
> >
> >      [ENOTDIR]     A component of the path prefix is not a directory.
> >
> > suggesting again that the thing called "Attic" was not a directory in
> > Alexei's repository (until after it was manually made to be one).
> POSIX (or at least SUS2, which is all I have on-line access to) is
> unfortunately a bit fuzzy in this area.  opendir() says:
>     [ENOENT]    A component of dirname does not name an existing
>                 directory or dirname is an empty string.
>     [ENOTDIR]   A component of dirname is not a directory.
> which seems to leave it ambiguous as to which is returned for a non-
> existent directory.  Of course, we all know that ENOENT is the right
> choice.
> > If not then Alexei's operating system does have a serious bug or is at
> > least not very POSIX compatible.
> I've taken a quick look at the cygwin source (which is what Alexei is
> using) and it appears that opendir() has a pechant for returning ENOTDIR
> for nearly all errors whereas ENOENT would probably be a better choice
> in most cases.
> -Larry Jones
> I'm so disappointed. -- Calvin

reply via email to

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