The openpty() routine has been modified to use the extra pty names
before the "traditional" names, so that programs too dumb to use
openpty() will, hopefully, find one of the "traditional" ptys free
even if many others are in use. The modifications to MAKEDEV are
courtesy Andrew Brown, and are pretty clever: the unit numbers used
by the "traditional" names stay the same, to avoid trouble when
upgrading existing systems. The unusual use of "dd" to index an
array in MAKEDEV is because no other simple method seemed feasible
using only the programs on the install media for all ports.
descriptors against -1 (as appropriate).
* add actual checks which to detect stuff that would trigger_DIAGASSERT(),
and attempt to return a sane error condition.
* knf some code
* remove some `register' decls.
the first two items result in the addition of code similar to the
following in various functions:
_DIAGASSERT(path != NULL)
#ifdef _DIAGNOSTIC
if (path == NULL) {
errno = EFAULT;
return (-1);
}
#endif