sdelay: reduce function to just one line
authorFabio Erculiani <lxnay@sabayon.org>
Tue, 11 Jan 2011 23:32:35 +0000 (00:32 +0100)
committerFabio Erculiani <lxnay@sabayon.org>
Tue, 11 Jan 2011 23:33:19 +0000 (00:33 +0100)
defaults/initrd.scripts

index 4da6968492db40af3fc99875ca6f2db8e5a29a8e..d672e5575511320bc4413d6386aa35fc9534968a 100755 (executable)
@@ -883,12 +883,7 @@ startLUKS() {
 sdelay() {
        # Sleep a specific number of seconds if SDELAY is set otherwise only sleep
        # 3 seconds, which is a much better default than 1 second (previous default)
-       if [ "${SDELAY}" ]
-       then
-               sleep ${SDELAY}
-       else
-               sleep 3
-       fi
+       sleep ${SDELAY:-3}
 }
 
 quiet_kmsg() {