]> code.ossystems Code Review - openembedded-core.git/commitdiff
sysvinit: bootlogd: Honor VERBOSE
authorRichard Tollerton <rich.tollerton@ni.com>
Tue, 22 Jul 2014 20:23:34 +0000 (15:23 -0500)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Wed, 23 Jul 2014 20:47:17 +0000 (21:47 +0100)
The messages echoed when starting and stopping bootlogd are currently
printed regardless of the setting of VERBOSE.  Adjust the initscript so
they're only printed when VERBOSE is enabled.

Signed-off-by: Richard Tollerton <rich.tollerton@ni.com>
Signed-off-by: Ben Shelton <ben.shelton@ni.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-core/sysvinit/sysvinit/bootlogd.init

index 7d6518d9814d024806f7666bc33bbedc74e12112..06af465a5b52fd1cbd748f850a2b547d4bd53e86 100755 (executable)
@@ -46,7 +46,7 @@ esac
 
 case "$ACTION" in
        start)
-               echo -n "Starting $DESC: "
+               [ "${VERBOSE}" != "no" ] && echo -n "Starting $DESC: "
                if [ -d /proc/1/. ]
                then
                        umask 027
@@ -55,10 +55,12 @@ case "$ACTION" in
                else
                        $DAEMON -r -c
                fi
-               echo "$NAME."
+               [ "${VERBOSE}" != "no" ] && echo "$NAME."
                ;;
        stop)
-               echo -n "Stopping $DESC: "
+               # stop may get called during bootup, so let it honor
+               # rcS VERBOSE setting
+               [ "${VERBOSE}" != "no" ] && echo -n "Stopping $DESC: "
                start-stop-daemon --stop --quiet --exec $DAEMON
 
                if [ "$STOPPER" ] && [ -f /var/log/boot ] && \
@@ -71,7 +73,7 @@ case "$ACTION" in
                        mv boot~ boot.0
                fi
 
-               echo "$NAME."
+               [ "${VERBOSE}" != "no" ] && echo "$NAME."
                ;;
         restart|force-reload)
                echo -n "Restarting $DESC: "