diff options
author | Kurt J. Bosch <kjb-temp-2009@alpenjodel.de> | 2011-07-12 08:56:11 +0200 |
---|---|---|
committer | Tom Gundersen <teg@jklm.no> | 2011-07-17 21:38:00 +0200 |
commit | 81c36b2f88b03b098bcf41a9036dfe06d081c74f (patch) | |
tree | d463c1d48bff782e49f7e84ee6f189ff6124b9b6 /rc.sysinit | |
parent | f5641931faa2f6cc29985d70b90cc79bf752d62e (diff) |
Fix/unify quoting
The rules should be:
* Use quotes when literal strings are involved.
* Use quotes when ever using a substitution which might produce blanks
as a possitional parameter unless word splitting is intended.
* Use quotes on the right hand side within '[[ = ]]'
unless pattern matching is intended.
* Don't use quotes for substitutions where not needed as in assignments.
Diffstat (limited to 'rc.sysinit')
-rwxr-xr-x | rc.sysinit | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -96,14 +96,14 @@ if [[ -f /etc/crypttab && $CS ]] && grep -q ^[^#] /etc/crypttab; then # $3 = password # $4 = options stat_append "${1}.." - local open=create a="$1" b="$2" failed=0 + local open=create a=$1 b=$2 failed=0 # Ordering of options is different if you are using LUKS vs. not. # Use ugly swizzling to deal with it. # isLuks only gives an exit code but no output to stdout or stderr. if $CS isLuks "$2" 2>/dev/null; then open=luksOpen - a="$2" - b="$1" + a=$2 + b=$1 fi case $3 in SWAP) @@ -179,7 +179,7 @@ declare -r FORCEFSCK run_hook sysinit_prefsck if [[ -x $(type -P fsck) ]]; then stat_busy "Checking Filesystems" - fsck_all >|${FSCK_OUT:-/dev/stdout} 2>|${FSCK_ERR:-/dev/stdout} + fsck_all >|"${FSCK_OUT:-/dev/stdout}" 2>|"${FSCK_ERR:-/dev/stdout}" declare -r fsckret=$? (( fsckret <= 1 )) && stat_done || stat_fail else |