and then NUM_CONSOLES is used outside this if:
So define NUM_CONSOLE again as it is did at line 105.
Attached patch is for the purpose.
Regards,
--- console-screen.sh.orig 2007-06-22 23:56:22.000000000 +0900
+++ console-screen.sh 2007-06-22 23:56:05.000000000 +0900
@@ -213,6 +213,13 @@
if [ "$LEDS" != "" ]
then
i=1
+ if [ -z "$NUM_CONSOLES" ] ; then
+ # if SCREEN_FONT is not explicitly specified in config,
+ # we must set NUM_CONSOLES here.
+ NUM_CONSOLES=`fgconsole --next-available`
+ NUM_CONSOLES=$(($NUM_CONSOLES - 1))
+ [ ${NUM_CONSOLES} -eq 1 ] && NUM_CONSOLES=6
+ fi
while [ $i -lt $NUM_CONSOLES ]
do
setleds -D $LEDS < $DEVICE_PREFIX$i