psplash: improve how to detect boot param to avoid the psplash starting
authorOtavio Salvador <otavio@ossystems.com.br>
Mon, 23 Feb 2009 17:19:34 +0000 (14:19 -0300)
committerOtavio Salvador <otavio@ossystems.com.br>
Mon, 23 Feb 2009 17:32:05 +0000 (14:32 -0300)
It was done using a looping through cmdline contents but it failed
depending on params order; using a grep makes it works more reliably.

packages/psplash/files/psplash-init
packages/psplash/psplash_svn.bb

index 7796a79..a4fb1dc 100644 (file)
@@ -1,13 +1,9 @@
 #!/bin/sh 
 
-for x in $(cat /proc/cmdline); do
-        case $x in
-        psplash=false)
-               echo "Boot splashscreen disabled" 
-               exit 0;
-                ;;
-        esac
-done
+if grep -qE '\s?psplash=false\s?' /proc/cmdline; then
+       echo "Boot splashscreen disabled"
+       exit 0;
+fi
 
 . /etc/init.d/functions
 . /etc/default/psplash
index e7cbda5..f471396 100644 (file)
@@ -3,7 +3,7 @@ require psplash-ua.inc
 
 ALTERNATIVE_PRIORITY = "10"
 
-PR = "r17"
+PR = "r18"
 
 SRC_URI = "svn://svn.o-hand.com/repos/misc/trunk;module=psplash;proto=http \
           file://psplash-hand-img.h \