Don't try to chmod ptys if we have none.

This commit is contained in:
christos 2004-11-10 05:04:51 +00:00
parent cdfecd6b76
commit 573e338f96

View File

@ -1,6 +1,6 @@
#!/bin/sh
#
# $NetBSD: ttys,v 1.5 2004/08/13 18:08:03 mycroft Exp $
# $NetBSD: ttys,v 1.6 2004/11/10 05:04:51 christos Exp $
#
# PROVIDE: tty
@ -25,8 +25,9 @@ ttyflags_start()
# XXX: there may be more ptys than this; maybe use
# sysctl kern.maxptys to find out how many?
#
chmod 666 /dev/tty[p-uw-zP-T][0-9a-zA-Z]
if [ -c /dev/ttyp0 ]; then
chmod 666 /dev/tty[p-uw-zP-T][0-9a-zA-Z]
fi
# only change ttyv* if ttyv0 is not reserved by a console.
#
if [ -c /dev/ttyv1 ]; then