SOURCES: kbd.init - skip switchto if started from pty - skip DEVIC...
glen
glen at pld-linux.org
Thu Dec 7 22:12:00 CET 2006
Author: glen Date: Thu Dec 7 21:12:00 2006 GMT
Module: SOURCES Tag: HEAD
---- Log message:
- skip switchto if started from pty
- skip DEVICES assign if not neccessary
---- Files affected:
SOURCES:
kbd.init (1.28 -> 1.29)
---- Diffs:
================================================================
Index: SOURCES/kbd.init
diff -u SOURCES/kbd.init:1.28 SOURCES/kbd.init:1.29
--- SOURCES/kbd.init:1.28 Thu Dec 7 22:06:15 2006
+++ SOURCES/kbd.init Thu Dec 7 22:11:55 2006
@@ -52,25 +52,23 @@
fi
if [ -n "$CONSOLEFONT" -a -x /sbin/setsysfont ]; then
- CMD="/sbin/setsysfont"
show "Loading console font and map"
busy
# don't initialize on multiple terminals if we use fbset
# (assume that, in this case fb is loaded as a module)
if [ ! -z "$FB" ]; then
-
- # check if devfs (workaround: -a option doesn't work at all)
- if [ -d /dev/vc ]; then
- DEVICES=$(ls /dev/vc/)
- else
- DEVICES=$(awk -F: '/^[0-9]*:/{print $1}' /etc/inittab)
+ if [ -z "$SET_FONT_TERMINALS" ]; then
+ # check if devfs (workaround: -a option doesn't work at all)
+ if [ -d /dev/vc ]; then
+ SET_FONT_TERMINALS=$(ls /dev/vc/)
+ else
+ SET_FONT_TERMINALS=$(awk -F: '/^[0-9]*:/{print $1}' /etc/inittab)
+ fi
fi
- [ -z "$SET_FONT_TERMINALS" ] && SET_FONT_TERMINALS="$DEVICES"
-
for cons in $SET_FONT_TERMINALS; do
- /usr/bin/open -c $cons -s -w -- $CMD
+ /usr/bin/open -c $cons -s -w -- /sbin/setsysfont
if [ "$NUM_LOCK" ]; then
if [ $NUM_LOCK = "on" ]; then
/usr/bin/open -c $cons -s -w -- /usr/bin/setleds -D +num
@@ -80,9 +78,11 @@
fi
done
- /usr/bin/switchto $tty
+ if [[ "$tty" = [0-9]* ]]; then
+ /usr/bin/switchto $tty
+ fi
else
- $CMD
+ /sbin/setsysfont
fi
ok
fi
@@ -122,7 +122,9 @@
for cons in $SET_FONT_TERMINALS; do
/usr/bin/open -c $cons -s -w -- /usr/bin/setterm $setterm_option
done
- /usr/bin/switchto $tty
+ if [[ "$tty" = [0-9]* ]]; then
+ /usr/bin/switchto $tty
+ fi
touch /var/lock/subsys/console
}
================================================================
---- CVS-web:
http://cvs.pld-linux.org/SOURCES/kbd.init?r1=1.28&r2=1.29&f=u
More information about the pld-cvs-commit
mailing list