Move pts master devices into /dev/pty/ instead of littering /dev with them;

this is more consistent with the placement of slaves in /dev/pts.  The
actual name doesn't matter as it's not part of the exposed API or used by
libc.  In some sense, it would be nice if these device nodes didn't have to
have names in devfs at all.

Suggested by:	Stephen McKay <smckay at internode dot on dot net>
This commit is contained in:
Robert Watson 2006-01-30 11:59:19 +00:00
parent 01d86f980f
commit 4c0b19957f

View file

@ -851,8 +851,8 @@ pty_clone(void *arg, struct ucred *cred, char *name, int namelen,
* an open() or we won't create a device".
*/
pt->pt_devc = devc = make_dev_cred(&ptc_cdevsw,
NUM_TO_MINOR(pt->pt_num), cred, UID_ROOT, GID_WHEEL, 0666, "pty%d",
pt->pt_num);
NUM_TO_MINOR(pt->pt_num), cred, UID_ROOT, GID_WHEEL, 0666,
"pty/%d", pt->pt_num);
dev_ref(devc);
devc->si_drv1 = pt;