to POSIX.2. In particular:
- don't retry for ETXTBSY. This matches what sh(1) does. The retry code
was broken anyway. It only slept for several seconds for the first few
retries. Then it retried without sleeping.
- don't abort the search for errors related to the path prefix, in
particular for ENAMETOOLONG, ENOTDIR, ELOOP. This fixes PR1487. sh(1)
gets this wrong in the opposite direction by never aborting the search.
- don't confuse EACCES for errors related to the path prefix with EACCES
for errors related to the file. sh(1) gets this wrong.
- don't return a stale errno when the search terminates normally without
finding anything. The errno for the last unsuccessful execve() was
usually returned. This gave too much precedence to pathologies in the
last component of $PATH. This bug is irrelevant for sh(1).
The implementation still uses the optimization/race-inhibitor of trying
to execve() things first. POSIX.2 seems to require looking at file
permissions using stat(). We now use stat() after execve() if execve()
fails with an ambiguous error. Trying execve() first may actually be a
pessimization, since failing execve()s are fundamentally a little slower
than stat(), and are significantly slower when a file is found but has
unsuitable permissions or points to an unsuitable interpreter.
PR: 1487
'slow' lookup if we get a YPERR_MAP (no such map in server's domain) error
instead of failing over on any error. In the latter case, if the 'fast'
search fails legitimately (i.e. the user or host really isn't a member
of the specified netgroup) then we end up doing the 'slow' search and
failing all over again. The result is still correct, but cycles are
consumed for no good reason.
Also removed the #ifdef CHARITABLE since the compat kludge is no longer
optional.
Forgotten-By: rgrimes, early '94 (see rev 1.3, 1.4).
2) Use 555-#### examples to avoid potentially expensive accidents.
3) Escape @ in example pn capability (see related FAQ.sgml question).
Distribute all but the most fundamental malloc types. This time I also
remembered the trick to making things static: Put "static" in front of
them.
A couple of finer points by: bde
Now you can use one without entering the other and it will DTRT.
These changes just allowed me to do the most straight-forward new disk
installation I've ever managed with sysinstall.
the descend can jump several directories down in one hit, eg: when a user
mentions multiple directories on the command line, eg: "cvs diff
sys/i386/isa/snd sys/sys". The problem is that the chdir()s are
pushed/popped to account for this, but the "full path" merely has
the last component chopped off on the way back up. This busts lots
of things when the recursion is backing up more than one directory (such
as in the example). This causes 'cvs diff' to emit bogus Index: lines,
'cvs update' to do really stupid things, 'cvs commit' to record incorrect
pathnames etc. I'm not sure that what I've done is quite correct, there
seems to be a comment that implies some sort of problem with "." vs. ""
equivalence or not, perhaps this is a problem on some other OS's, but
I've not (yet) found any problems. This bug has been present since
at least cvs-1.8.1.
This should fix problems noted by several people including asami and jmg.