dracut-lib: fixed quiet argument parsing
authorHarald Hoyer <harald@redhat.com>
Fri, 17 Jul 2009 08:13:01 +0000 (10:13 +0200)
committerHarald Hoyer <harald@redhat.com>
Fri, 17 Jul 2009 08:13:01 +0000 (10:13 +0200)
modules.d/99base/dracut-lib.sh

index 235e313e0543a749c609596feef376cebd7c3024..f9182cfd773583aab4f8b4493b618569365c9856 100644 (file)
@@ -48,10 +48,13 @@ warn() {
 }
 
 info() {
-    [ "$DRACUT_QUIET" ] || DRACUT_QUIET="x$(getarg quiet)"
+    if [ -z "$DRACUT_QUIET" ]; then
+       DRACUT_QUIET="no"
+       getarg quiet && DRACUT_QUIET="yes"
+    fi
     echo "<6>dracut: $@" > /dev/kmsg
-    [ "$DRACUT_QUIET" != "xquiet" ] && \
-       echo "dracut: $@" > /dev/console
+    [ "$DRACUT_QUIET" != "yes" ] && \
+       echo "dracut: $@" 
 }
 
 vinfo() {